0

we have one react application and start it using pm2 with pm2 start manually. We have written one script to run it, it is working as expected when we run script manually on server. But when calling from jenkins it is not working as expected.

Below is jenkins job conf:

ssh remote_server_hostname@ip <<'ENDSSH'
cd /home/scripts
./start_reactApp.sh &>> /dev/null
echo "Script executed on remote server successfully"
ENDSSH
Rob
  • 1,175
  • 1
  • 7
Satish Lamak
  • 51
  • 1
  • 3
  • 7
  • Care to elaborate what is "expected" and what is the "unexpected" result you are receiving? – Paperclip Apr 29 '22 at 13:26
  • expected result is application should be up and running when we call script from jenkins. on the other hand if we run script manually by login to server the application works fine. – Satish Lamak May 02 '22 at 06:48
  • Perhaps if you remove the output redirection to /dev/null you can see some error output. – Paperclip May 02 '22 at 07:11
  • I tried that one as well, script ran successfully but application not getting up – Satish Lamak May 04 '22 at 06:19

0 Answers0