Jump to content

Emby theater menu buttons "Shutdown" and "Sleep" do not work on Linux


LorenJ

Recommended Posts

The emby theater menu buttons for Shutdown and Sleep are not working (will not shutdown or put pc to sleep) on Kubuntu / Ubuntu installation. I have tried theater on several pc's to see if it was a hardware issue to no avail, as the buttons just will not function. The "Sleep" button does not give a error after exiting theater but the "Shutdown" button points to a JavaScript error after exiting. I am running the latest distro of Kubuntu (KDE Plasma 5.26.3) and the latest versions of emby server (4.7.9.0) and emby theater (3.0.16). The JavaScript error (screen shot attached) points to the /power-off/ folder but no error appears when clicking the Sleep button after exiting the theater app. I have installed Ubuntu X64 via *.deb distro "plexmediaserver_1.29.2.6364-6d72b0cf6_amd64.deb" for the server and "emby-theater-deb_3.0.16_amd64.deb" for theater. Just trying the see if anyone else has this issue and see if there is a fix for .js files. Thanks

emby script error on shutdown.jpg

emby theater menu functions do not work.jpg

emby server 4_7_9_0 and emby theater 3_0_16 install.jpg

OS configuration.jpg

Link to comment
Share on other sites

Thanks for looking into this Luke. I patched the JavaScript file at

root/opt/emby-theater/electron/resources/app/node_modules/power-off/index.js on line 11 to read " cmd = 'shutdown -h now'; "

That fixed the power off problem for me.

then

root/opt/emby-theater/electron/resources/app/node_modules/sleep-mode/index.js on line 15 to read "cmd = 'systemctl suspend'"

and that fixed sleep for me. I would have preferred to go into hibernate at the sleep function but I could not get around the password trap so I found this "obsolete"  cmd line.

---------------

For reference, I am logging in to Kubuntu without a password (set as login without password), and when I noticed ref to  "SUDO" in the original EMBY .js script I suspected this could be looking for a password. I am also running without wallet keeping track of anything (if that's any help at all).

Thanks LJF

  • Thanks 1
Link to comment
Share on other sites

Luke, Here are snapshots  of the index.js files for power-off and sleep-mode. It works for me but probably not the correct way to get it working for everyone.    LJF

revised index.js for power-off.jpg

revised index.js for sleep-mode .jpg

  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...