This project can be used as a starting point to create your Java web application (f.e. Springboot) which is being wrapped in an electron application. For the build process maven is being used only. This project contains all the necessary configuration and some placeholder files to get you started.
This project was inspired a lot by electron-java-app, but has some key differences:
- Relies for building purposes purely on maven (ofcourse also Node but indirectly)
- Includes OpenJDK
- The electron app uses the shipped OpenJDK
mvn clean install -Pproduction
The artifacts from the electron build will be put into:
target\electron\springboot-on-electron-darwin-x64
target\electron\springboot-on-electron-win32-x64
When using Mac OS or linux, wine
is required to build windows
(check the maven build for further informations).
When using Windows, admin privileges are required to build darwin
(check the maven build for further informations).
Since not all your users have a JVM available via the classpath a OpenJDK 8 will be packed into the electron builds
When executing mvn clean install -Pproduction
by default the windows
(x64) and darwin
(x64) will be build.
The rest is currently not supported but adding those shouldn't be to hard but some changes will need to be made at the following files: