[ec2-user@ip-172-31-12-220 frontend]$ sudo vim /etc/systemd/system/frontend.service
[Unit] Description=My react.js Application After=network.target
[Service] Type=simple User=ec2-user WorkingDirectory=/home/ec2-user/codedamn_pg/frontend ExecStart=sudo yarn dev Restart=always RestartSec=5s
[Install] WantedBy=multi-user.target