Verinice/Kompilieren: Unterschied zwischen den Versionen
Zeile 26: | Zeile 26: | ||
==== Weblinks ==== | ==== Weblinks ==== | ||
# https://forum.verinice.com/t/1-23-0-kompilieren/1512/7 | |||
== Testfragen == | == Testfragen == |
Version vom 15. April 2023, 13:01 Uhr
Vernice Client, Update-Site und Server kompilieren
Beschreibung
Installation
Syntax
Optionen
Parameter
Umgebungsvariablen
Exit-Status
Anwendungen
Fehlerbehebung
Konfiguration
Dateien
Siehe auch
Unterseiten
Sicherheit
Dokumentation
RFC
Man-Pages
Info-Pages
Links
Einzelnachweise
Projekt
Weblinks
Testfragen
Testfrage 1
Antwort1
Testfrage 2
Antwort2
Testfrage 3
Antwort3
Testfrage 4
Antwort4
Testfrage 5
Antwort5
TMP
Beschreibung
- Windows
- Mac
- Linux
Umgebung
Betriebssystem
$ cat /etc/os-release PRETTY_NAME="Debian GNU/Linux bookworm/sid"
Java
$ java -version openjdk version "11.0.17" 2022-10-18 OpenJDK Runtime Environment (build 11.0.17+8-post-Debian-2) OpenJDK 64-Bit Server VM (build 11.0.17+8-post-Debian-2, mixed mode, sharing)
$ echo $JAVA_HOME /usr/lib/jvm/default-java/
$ ls -l /usr/lib/jvm/ lrwxrwxrwx 1 root root 25 25. Nov 12:24 default-java -> java-1.11.0-openjdk-amd64 lrwxrwxrwx 1 root root 21 18. Okt 2019 java-1.11.0-openjdk-amd64 -> java-11-openjdk-amd64 lrwxrwxrwx 1 root root 21 20. Jan 2022 java-1.17.0-openjdk-amd64 -> java-17-openjdk-amd64 lrwxrwxrwx 1 root root 21 17. Feb 2022 java-1.18.0-openjdk-amd64 -> java-18-openjdk-amd64 lrwxrwxrwx 1 root root 21 19. Okt 07:16 java-1.19.0-openjdk-amd64 -> java-19-openjdk-amd64 drwxr-xr-x 9 root root 4,0K 14. Nov 07:35 java-11-openjdk-amd64 lrwxrwxrwx 1 root root 21 21. Okt 10:28 java-1.20.0-openjdk-amd64 -> java-20-openjdk-amd64 drwxr-xr-x 9 root root 4,0K 25. Nov 11:50 java-17-openjdk-amd64 lrwxrwxrwx 1 root root 20 24. Apr 2022 java-1.8.0-openjdk-amd64 -> java-8-openjdk-amd64 drwxr-xr-x 9 root root 4,0K 25. Nov 11:50 java-18-openjdk-amd64 drwxr-xr-x 9 root root 4,0K 25. Nov 11:50 java-19-openjdk-amd64 drwxr-xr-x 9 root root 4,0K 25. Nov 11:50 java-20-openjdk-amd64 drwxr-xr-x 5 root root 4,0K 27. Apr 2022 java-8-openjdk-amd64 drwxr-xr-x 2 root root 4,0K 25. Nov 11:50 openjdk-11 drwxr-xr-x 2 root root 4,0K 25. Nov 11:50 openjdk-17 drwxr-xr-x 2 root root 4,0K 25. Nov 11:50 openjdk-18 drwxr-xr-x 2 root root 4,0K 25. Nov 11:50 openjdk-19 drwxr-xr-x 2 root root 4,0K 25. Nov 11:50 openjdk-20
Quellen bereitstellen
$ cd /usr/srv $ git clone https://github.com/SerNet/verinice Klone nach 'verinice'... remote: Enumerating objects: 148244, done. remote: Counting objects: 100% (6964/6964), done. remote: Compressing objects: 100% (2221/2221), done. remote: Total 148244 (delta 4588), reused 6150 (delta 4235), pack-reused 141280 Empfange Objekte: 100% (148244/148244), 1.23 GiB | 8.96 MiB/s, fertig. Löse Unterschiede auf: 100% (95543/95543), fertig. Aktualisiere Dateien: 100% (12390/12390), fertig.
- Basisverzeichnis
$ ls /usr/srv/verinice bouncycastle sernet.birt.feature sernet.thirdparty.feature CODINGSTYLE.md sernet.client.service sernet.verinice.app.feature COPYRIGHT.md sernet.client.service.handlerrights sernet.verinice.bp.importer dependencies sernet.datatools.feature sernet.verinice.desktop.integration doc sernet.eclipse.feature sernet.verinice.extraresources.feature gnumail sernet.gs.db.fragment sernet.verinice.extraresources.jre_linux_64 gui-test-runner sernet.gs.ehcache.fragment sernet.verinice.extraresources.jre_macos_64 jbpm sernet.gs.hibernate.fragment sernet.verinice.extraresources.jre_win_64 Jenkinsfile sernet.gs.log4j.fragment sernet.verinice.fei.rcp Jenkinsfile.nightly sernet.gs.pax_web.fragment sernet.verinice.fei.service Jenkinsfile.rcptt-all-report-tests sernet.gs.reveng sernet.verinice.kerberos Jenkinsfile.rcptt-client-performance-test sernet.gs.server sernet.verinice.lang.feature Jenkinsfile.rcptt-client-test sernet.gs.server.feature sernet.verinice.oda.driver Jenkinsfile.rcptt-product-report-test sernet.gs.server.tests sernet.verinice.releng.client.product Jenkinsfile.rcptt-server-performance-test sernet.gs.service sernet.verinice.releng.server.product Jenkinsfile.server-rcptt-test sernet.gs.service.tests sernet.verinice.report.service LICENSE sernet.gs.springweb.fragment sernet.verinice.samt.rcp mvnw sernet.gs.ui.rcp.main sernet.verinice.samt.service mvnw.cmd sernet.gs.ui.rcp.main.tests target-platform notes sernet.hui.common TCOracle.pdf org.eclipse.e4.rcp.sernet sernet.hui.swtclient verinice-distribution pom.xml sernet.localdependencies verinice-gui-tests README.md sernet.rcp.ui.feature waffle SECURITY.md sernet.springclient
- Umgebung bereinigen
$ rm -r ~/.m2/
Java integrieren
https://jdk.java.net/
Linux
$ mkdir -p sernet.verinice.extraresources.jre_linux_64/jre $ cp -Lr $JAVA_HOME* sernet.verinice.extraresources.jre_linux_64/jre/
$ ls sernet.verinice.extraresources.jre_linux_64/jre bin conf docs legal lib man release
Windows
# mkdir -p sernet.verinice.extraresources.jre_win_64/jre $ wget https://download.java.net/java/GA/jdk11/9/GPL/openjdk-11.0.2_windows-x64_bin.zip -P /tmp
$ unzip /tmp/openjdk-11.0.2_windows-x64_bin.zip -d /tmp/openjdk-11.0.2_windows-x64_bin
$ cp -Lr /tmp/openjdk-11.0.2_windows-x64_bin/jdk-11.0.2/* sernet.verinice.extraresources.jre_win_64/jre
$ ls sernet.verinice.extraresources.jre_win_64/jre bin conf include jmods legal lib release
MacOS
# mkdir -p sernet.verinice.extraresources.jre_macos_64/jre $ wget https://download.java.net/java/GA/jdk11/9/GPL/openjdk-11.0.2_osx-x64_bin.tar.gz -P /tmp
$ mkdir /tmp/openjdk-11.0.2_osx-x64_bin; tar --directory=/tmp/openjdk-11.0.2_osx-x64_bin -xf /tmp/openjdk-11.0.2_osx-x64_bin.tar.gz
$ cp -Lr /tmp/openjdk-11.0.2_osx-x64_bin/jdk-11.0.2.jdk/Contents/Home/* sernet.verinice.extraresources.jre_macos_64/jre
$ ls sernet.verinice.extraresources.jre_macos_64/jre/ bin conf include jmods legal lib release
Hinweise zu Versionen
Verinice 1.23.1
In der Datei sernet.gs.server/pom.xml alle http: durch https: ersetzen
# sed -i 's/http:/https:/g' sernet.gs.server/pom.xml
Kompilieren
$ cd /usr/srv/verince $ ./mvnw -Dtycho.disableP2Mirrors=true clean verify [...] Results: Tests run: 75, Failures: 0, Errors: 0, Skipped: 0 [INFO] All tests passed! [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] sernet.verinice.tycho.root 1.25.0-SNAPSHOT ......... SUCCESS [ 0.430 s] [INFO] target-platform 1.25.0-SNAPSHOT .................... SUCCESS [ 0.066 s] [INFO] jbpm 4.4.1 ......................................... SUCCESS [ 5.107 s] [INFO] org.eclipse.e4.rcp.sernet 1.25.0-SNAPSHOT .......... SUCCESS [ 5.269 s] [INFO] sernet.birt.feature 1.25.0-SNAPSHOT ................ SUCCESS [ 20.659 s] [INFO] sernet.datatools.feature 1.25.0-SNAPSHOT ........... SUCCESS [ 6.668 s] [INFO] sernet.eclipse.feature 1.25.0-SNAPSHOT ............. SUCCESS [ 6.686 s] [INFO] sernet.gs.db.fragment 1.25.0-SNAPSHOT .............. SUCCESS [ 0.139 s] [INFO] sernet.gs.ehcache.fragment 1.25.0-SNAPSHOT ......... SUCCESS [ 0.067 s] [INFO] sernet.gs.hibernate.fragment 1.25.0-SNAPSHOT ....... SUCCESS [ 0.040 s] [INFO] sernet.gs.log4j.fragment 1.25.0-SNAPSHOT ........... SUCCESS [ 0.024 s] [INFO] sernet.gs.pax_web.fragment 1.25.0-SNAPSHOT ......... SUCCESS [ 3.350 s] [INFO] sernet.gs.reveng 1.25.0-SNAPSHOT ................... SUCCESS [ 3.584 s] [INFO] sernet.hui.common 1.25.0-SNAPSHOT .................. SUCCESS [ 5.568 s] [INFO] sernet.gs.service 1.25.0-SNAPSHOT .................. SUCCESS [ 3.682 s] [INFO] sernet.hui.swtclient 1.25.0-SNAPSHOT ............... SUCCESS [ 3.585 s] [INFO] sernet.springclient 1.25.0-SNAPSHOT ................ SUCCESS [ 32.863 s] [INFO] sernet.gs.ui.rcp.main 1.25.0-SNAPSHOT .............. SUCCESS [ 26.362 s] [INFO] sernet.verinice.oda.driver 1.25.0-SNAPSHOT ......... SUCCESS [ 1.658 s] [INFO] sernet.verinice.samt.service 1.25.0-SNAPSHOT ....... SUCCESS [ 0.344 s] [INFO] sernet.verinice.report.service 1.25.0-SNAPSHOT ..... SUCCESS [ 3.134 s] [INFO] sernet.verinice.fei.service 1.25.0-SNAPSHOT ........ SUCCESS [ 0.321 s] [INFO] sernet.gs.server 1.25.0-SNAPSHOT ................... SUCCESS [05:38 min] [INFO] sernet.gs.server.feature 1.25.0-SNAPSHOT ........... SUCCESS [ 0.057 s] [INFO] sernet.gs.springweb.fragment 1.25.0-SNAPSHOT ....... SUCCESS [ 0.018 s] [INFO] sernet.localdependencies 1.25.0-SNAPSHOT ........... SUCCESS [ 0.011 s] [INFO] sernet.verinice.fei.rcp 1.25.0-SNAPSHOT ............ SUCCESS [ 2.119 s] [INFO] sernet.verinice.samt.rcp 1.25.0-SNAPSHOT ........... SUCCESS [ 1.843 s] [INFO] sernet.verinice.desktop.integration 1.25.0-SNAPSHOT SUCCESS [ 0.395 s] [INFO] waffle 1.7.4 ....................................... SUCCESS [ 0.076 s] [INFO] sernet.verinice.kerberos 1.25.0-SNAPSHOT ........... SUCCESS [ 0.504 s] [INFO] sernet.rcp.ui.feature 1.25.0-SNAPSHOT .............. SUCCESS [ 0.083 s] [INFO] sernet.thirdparty.feature 1.25.0-SNAPSHOT .......... SUCCESS [ 6.673 s] [INFO] sernet.verinice.lang.feature 1.25.0-SNAPSHOT ....... SUCCESS [ 20.592 s] [INFO] sernet.verinice.extraresources.jre_linux_64 1.25.0-SNAPSHOT SUCCESS [ 3.935 s] [INFO] sernet.verinice.extraresources.jre_win_64 1.25.0-SNAPSHOT SUCCESS [ 4.093 s] [INFO] sernet.verinice.extraresources.jre_macos_64 1.25.0-SNAPSHOT SUCCESS [ 4.202 s] [INFO] sernet.verinice.extraresources.feature 1.25.0-SNAPSHOT SUCCESS [ 0.051 s] [INFO] sernet.verinice.app.feature 1.25.0-SNAPSHOT ........ SUCCESS [ 0.087 s] [INFO] sernet.verinice.releng.client.product 1.25.0-SNAPSHOT SUCCESS [01:26 min] [INFO] sernet.verinice.releng.server.product 1.25.0-SNAPSHOT SUCCESS [ 24.593 s] [INFO] sernet.gs.server.tests 1.25.0-SNAPSHOT ............. SUCCESS [ 19.369 s] [INFO] sernet.gs.service.tests 1.25.0-SNAPSHOT ............ SUCCESS [ 4.358 s] [INFO] sernet.gs.ui.rcp.main.tests 1.25.0-SNAPSHOT ........ SUCCESS [ 13.346 s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 14:11 min [INFO] Finished at: 2022-11-25T12:51:01+01:00 [INFO] ------------------------------------------------------------------------
Update
- Backup
# apt install pigz $ cd /usr/src/ $ tar -cf verinice_$(date +%Y-%m-%d-%H%M%S).tar.gz -I pigz verinice/
- Umgebung bereinigen
$ cd verinice $ rm -r ~/.m2/
- Quellen aktualisieren
- Kompilation
./mvnw -Dtycho.disableP2Mirrors=true clean verify