I have a Spring boot application that is started as a service using Linux's systemd.
It is based on this documentation : http://docs.spring.io/spring-boot/docs/current/reference/html/deployment-install.html
With the default script, the jar file start. It works fine.
/etc/systemd/system/myapp.service :
[Unit]
Description=myapp
After=syslog.target
[Service]
User=myapp
ExecStart=/var/myapp/myapp.jar
SuccessExitStatus=143
[Install]
WantedBy=multi-user.target
Now I want to add VM Option when the jar start. I tried to add a .conf file to the project but it doesn't work.
/var/myapp/myapp.conf :
JAVA_OPTS=-Xms256M -Xmx512M
How can I add JVM option to start the application with systemd ?