How can I restart Chromium after 2min of inactivity?
Would that be 2min restart of Chromium, potentially every two minutes forever? Perhaps you can explain the problem you are solving for?
Of course. I have a webapp that runs in Chromium. I need to ensure if the user has not used it for 2min, I would like for Chromium to restart, which will logoff the user. I am not able to set the logoff function in the webapp, so I need to control it in Chrome.
Hope this makes sense.
Hi Jake, indeed.
Have you been able to check if any “Chromium” / “Chrome” extensions are available to fit your need for idle logoff?
Another approach could be to run a script that runs every minute (using a cron-job):
1. Check if IGEL OS UI has been idle for two minutes
2. If so “kill chromium-browser”
3. If chromium is configured as a “custom-application” that is set to “Restart”, then it would relaunch at that point. If configured to clear cache, then it would then be like starting anew.
Are your devices running in appliance mode, for this use-case?
@member Another approach is to leverage the Screensaver’s idle detection, and close/reopen Chromium. (_pnlogoff -f; wmctrl -lix |grep ‘Chromium-browser’|cut -d ‘ ‘ -f 1 |xargs -i% wmctrl -i -c %; fi_) I’d worked on this in the past, but never used it in production. The following Profile XML would be a good start. It does need a local user/password as part of the process, and may need a little tweaking… If anyone else have used this method, feel free to jump in.
Continue reading and comment on the thread ‘How can I restart Chromium after 2min of inactivity?’. Not a member? Join Here!
Learn more, search the IGEL Knowledge Base
Ask a question or comment on the above message thread?Join or log in to the IGEL Community to ask us anything and meet other IGEL customers, partners, and EUC enthusiasts.
Submit a question, or Join Today!