Example

Myexample
[Unit]
Description=Example
[Service]
Type=simple #for java, should not be forking#note the bash should specify its full pathExecStart=/bin/bash /home/ubuntu/myapp.sh
[Install]
WantedBy=multi-user.target