Reputation: 497
I have a jar named my-app-0.0.1-SNAPSHOT.jar. I have to pass -XX:+UseG1GC -Xmx1g -Xms512m to the jar like
sudo java -XX:+UseG1GC -Xmx1g -Xms512m -jar my-app-0.0.1-SNAPSHOT.jar
I've created the .sh using above command. I use this single line bash script file in my-app.service to execute the .jar. Now I need to put everything in .service file. No .sh in picture. How to put those in the .service file? Any help is appreciated.
Upvotes: 1
Views: 539