Wiki-Quellcode von 05 Installation ONYX Player und Reporter
Zuletzt geändert von Carina Enke am 26.11.2025
Verstecke letzte Bearbeiter
| author | version | line-number | content |
|---|---|---|---|
![]() |
367.2 | 1 | {{section}} |
| 2 | {{column width="60%"}} | ||
![]() |
359.2 | 3 | == Requirements == |
![]() |
120.1 | 4 | |
![]() |
359.2 | 5 | * Java 17 (Oracle or OpenJDK) and Apache Tomcat 9 |
| 6 | * Apache Webserver with proxy_ajp and mod_rewrite (optional) | ||
| 7 | * MAXIMA for the use of calculations (mandatory) | ||
![]() |
120.1 | 8 | |
![]() |
367.2 | 9 | |
| 10 | {{/column}} | ||
![]() |
120.1 | 11 | |
![]() |
367.2 | 12 | {{column width="30%"}} |
| 13 | {{panel title="Inhalt"}} | ||
| 14 | {{toc start="2"/}} | ||
![]() |
359.2 | 15 | {{/panel}} |
![]() |
367.2 | 16 | {{/column}} |
| 17 | {{/section}} | ||
| 18 | |||
| 19 | |||
![]() |
120.1 | 20 | == Download == |
| 21 | |||
![]() |
359.2 | 22 | * Download and install OpenJDK 17 ([[https:~~/~~/jdk.java.net/java-se-ri/17>>url:https://jdk.java.net/java-se-ri/17||shape="rect"]] ) or Oracle JDK17 ([[https:~~/~~/jdk.java.net/17>>url:https://jdk.java.net/17||shape="rect"]]) |
![]() |
120.1 | 23 | |
![]() |
359.2 | 24 | {{code language="powershell"}} |
| 25 | tar xfz jdk-xyz-linux-x64.tar.gz -C /opt | ||
![]() |
120.1 | 26 | {{/code}} |
| 27 | |||
| 28 | * Let the environment variable $JAVA_HOME point to the JDK directory: | ||
| 29 | |||
![]() |
359.2 | 30 | {{code language="powershell"}} |
| 31 | export JAVA_HOME=/opt/jdkX.Y.Z | ||
![]() |
120.1 | 32 | {{/code}} |
| 33 | |||
![]() |
365.1 | 34 | * Download and install Tomcat 9: [[https:~~/~~/tomcat.apache.org/download-90.cgi>>url:https://tomcat.apache.org/download-90.cgi||rel="nofollow" shape="rect" title="Verknüpfung folgen"]] |
![]() |
120.1 | 35 | |
![]() |
359.2 | 36 | {{code language="powershell"}} |
| 37 | tar xfz apache-tomcat-X.Y.Z.tar.gz -C /opt | ||
![]() |
120.1 | 38 | {{/code}} |
| 39 | |||
![]() |
359.2 | 40 | === Download and install libraries === |
| 41 | |||
| 42 | {{code language="powershell"}} | ||
| 43 | yum install atk nss at-spi2-atk libXcomposite alsa-lib libXrandr libxkbcommon libXdamage cups-libs | ||
| 44 | {{/code}} | ||
| 45 | |||
![]() |
120.1 | 46 | == Deployment == |
| 47 | |||
| 48 | * Stop your Tomcat | ||
| 49 | * In case of an **update**, delete old ONYX war-files and dirs from ${TOMCAT_HOME}/webapps | ||
| 50 | * It might be useful to clear the work and temp directory of the Tomcat Server: | ||
| 51 | |||
![]() |
359.2 | 52 | {{code language="powershell"}} |
![]() |
120.1 | 53 | rm -rf ${TOMCAT_HOME}/temp/* ${TOMCAT_HOME}/work/* |
| 54 | {{/code}} | ||
| 55 | |||
![]() |
367.2 | 56 | |
![]() |
120.1 | 57 | * Copy the onyx-player-**X.X**.war to ${TOMCAT_HOME}/webapps |
| 58 | * Start your Tomcat | ||
| 59 | * Open the following URL in your browser: [[http:~~/~~/localhost:8080/onyx-player-X.X/demo>>url:http://localhost:8080/onyx-player-X.X/demo||shape="rect"]] | ||
| 60 | |||
| 61 | == Configuration of additional features == | ||
| 62 | |||
![]() |
359.2 | 63 | === Show example tests on your ONYX Player start page === |
![]() |
120.1 | 64 | |
| 65 | * Save the zip-files in /src/main/resources/tests | ||
| 66 | * Set showinternaltests to true (onyxplugin.config.xml) | ||
| 67 | |||
![]() |
359.2 | 68 | === Provide an upload functionality for tests on your ONYX Player start page === |
![]() |
120.1 | 69 | |
| 70 | * Define a folder in onyxplugin.config.xml where uploaded tests should be stored: <uploaddir>/tmp/</uploaddir> | ||
| 71 | * Note that this folder must exist and be writable or it must be allowed to create it. | ||
| 72 | * You can upload tests on your ONYX Player start page and access the tests directly via a static URL. | ||
| 73 | |||
| |
346.1 | 74 | === Install MAXIMA, if you like to use calculations === |
![]() |
120.1 | 75 | |
| |
346.1 | 76 | * Installation on RHEL/Fedora/CentOS: |
![]() |
120.1 | 77 | |
![]() |
359.2 | 78 | {{code language="powershell"}} |
| |
346.1 | 79 | sudo yum install maxima |
| 80 | {{/code}} | ||
![]() |
120.1 | 81 | |
| |
346.1 | 82 | * Installation on Debian/Ubuntu/Mint: |
![]() |
120.1 | 83 | |
![]() |
359.2 | 84 | {{code language="powershell"}} |
| |
346.1 | 85 | sudo yum install maxima |
| 86 | {{/code}} | ||
![]() |
120.1 | 87 | |
| |
346.1 | 88 | * Or visit [[http:~~/~~/maxima.sourceforge.net/>>url:http://maxima.sourceforge.net/||shape="rect"]] and download the MAXIMA files |
![]() |
120.1 | 89 | |
| |
346.1 | 90 | === Save user results === |
![]() |
120.1 | 91 | |
![]() |
359.2 | 92 | * ONYX allows **saving user results on the hard disk** **additionally to the transmission to the LMS**. This may be useful in case results cannot be transmitted due to errors in the LMS or during the transmission process. To activate this function enter the tag ((( |
| 93 | of the file onyxplugin.config.xml and adjust the indicated directory to your server. Tomcat needs a writing permission for this directory. The result files are sorted in a sub folder by date and will not be deleted. In case the result files are no longer required, deletion can be done only by administrators. | ||
| 94 | ))) | ||
![]() |
120.1 | 95 | |
| |
352.1 | 96 | {{code language="powershell"}} |
| |
346.1 | 97 | <resultsdir>/tmp/onyxresults/</resultsdir> in the section <playerconfig>...</playerconfig> |
| 98 | {{/code}} | ||
![]() |
120.1 | 99 | |
![]() |
359.2 | 100 | * You may configure ONYX Player to **automatically remove these result file copies after a certain time span**. The following option can be added to the configuration to activate this. Please configure a valid days number, after which all results older than this age will be removed. This is checked and executed once after ONYX startup and will run in a background task. If not configured, this is done after 30 days. |
| |
346.1 | 101 | |
![]() |
359.2 | 102 | {{code title="onyxplugin.config.xml"}} |
| 103 | <playerconfig> | ||
| 104 | ... | ||
| 105 | <!-- The timespan in days after which the result configured in resultsdir are automatically removed --> | ||
| 106 | <resultsdirCleanupAfterDays>30</resultsdirCleanupAfterDays> | ||
| 107 | ... | ||
| 108 | </playerconfig> | ||
| 109 | {{/code}} |
