Check out example codes for "how to make services in linux". It will help you in understanding the concepts better.
Code Example 1
[Unit] Description=<description about this service> [Service] User=<user e.g. root> WorkingDirectory=<directory_of_script e.g. /root> ExecStart=<script which needs to be executed> Restart=always [Install] WantedBy=multi-user.target
Learn ReactJs, React Native from akashmittal.com