A customer want to use a systemd startupscript, instead the solution proposed in the documentation https://github.com/mendix/m2ee-tools/blob/develop/doc/configure.md#at-reboot-cronjob, to start the app automatically after rebooting the server. He is not satisfied with the cronjob solution, as it might be removed after upgrading the OS. The startup script he created is starting the app already. Unfotunatelly, the javaprocess dies after some minutes without any feedback.
Does anyone have an idea what the problem might be? Here the used scriped:
---snip-- m2ee.service ---
[Unit]
Description=ExpertDesk m2ee
Requires=postgresql.service
After=postgresql.service
[Service]
Type=forking
User=expertdesk
ExecStartPre=/bin/m2ee stop
ExecStart=/bin/m2ee start
ExecStop=/bin/m2ee stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
--- snap ---