My script has below details
#!/bin/bash
PATH=$HOME/.gem/bin:$PATH
mkdir -p tmp data log
mkdir -p tmp/pids
mkdir -p tmp/sockets
unicorn -c unicorn.rb -l 0.0.0.0:8080
Platform Ruby2.1, linux Debian jessie
When I execute this script it goes into infinite loop with no result or not command line.
It works when I used port as 80. When I checked path $HOME/.gem/bin my location has /.gem/ folder but does not contain /bin in it. Please help
my PATH variables are :/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/usr/local/bin:/usr/local/bin/python2.7:/usr/bin/ruby2.1
Thank you very much
I was able to overcome this issue by running ./run command in another session in parallel.
Ex. When I run ./run command in 1st window it does not show any o/p and goes into infinite loop.
At same time if I open another linux terminal and run same command it completes within second and run's application. This is because 1st session open up port 8080 and when I run command again 8080 port is already open and hence program run successfully.