Run Google Chrome 24/7

I want to run Google Chrome 24/7 because there is an extension I need to use.
I have installed XFCE and TightVNC as described here:
and is working fine, I can login, see the desktop, execute chrome, my extension is running, everything is ok.
The problem is if I kill the vncserver then Chrome stops working (I think this is because vncserver is starting xfce?)
I’m very noob on these things please could you tell me what is the best way to keep Google Chrome open 24/7 (even if the system restarts or Chrome stops working).

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hi @enriquepiatti,

You can create a bash script to check if the service vncserver is actually running. If the service is not running start it.

You can see if a service is running with the following

systemctl show -p ActiveState NameOfService

It will show if the service is active,inactive or dead. Based on this output, you can actually decide whether to try and start it or leave as it is.

Once you create the bash script, add it as a cron job to be executed every minute. This should be enough to solve your problem.

Regards, KDSys