1 Answer
- Newest
- Most votes
- Most comments
0
Hi,
It's hard to understand what you are trying to achieve, but if you like to create a unit file for systems which will start your nextjs application you can use this https://gist.github.com/hardywu/361811f09130acae1762bfbf61a67e9c as template and this https://www.shubhamdipt.com/blog/how-to-create-a-systemd-service-in-linux/ as step by step instructions.
Hope it helps
answered 17 days ago
Relevant content
- asked 8 months ago
- asked 6 years ago
- AWS OFFICIALUpdated 4 months ago
- AWS OFFICIALUpdated 5 months ago
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated a year ago
The problem I am facing is that when I ssh to the instance, and type 'yarn', the command is found, but when used in script in systemd, or ApplicationStart in codedeploy, it always complain
yarn: command not found
.It could be because yarn is intalled in the homedir of specific user and systemd is trying to run it from the different user.