How to run ionic serve in background


#1

I am trying to run ionic serve in the background so I can test it via my rails app on circle ci. I thought I could do it with:

nohup bash -c “ionic serve --nolivereload --nobrowser &”

But unfortunately it doesn’t work. Does anyone know how to run it in the background?


#2

Did you find a way to accomplish this?


#3

And still no one knows how to start ionic in bg mode, run tests and then close ionic? No one runs e2e tests in a CI environment?


#4

Hi, working on it, if i succeed will share my solution here


#5

You only have to run the build command and open the index.html file
You don’t need the serve command.


#6

Try this:

sleep 999999999 | ionic serve --nolivereload --nobrowser &