Pistolero 0 Posted October 24, 2016 Posted October 24, 2016 Hi all, Question, is there a way to fully automate the upgrade of the Windows EmBy server, so no human interaction is needed for a complete install? Thanks!
Luke 39306 Posted October 24, 2016 Posted October 24, 2016 Hi, you could probably create something using the portable install. Why do you ask?
b0dyr0ck2006 57 Posted October 25, 2016 Posted October 25, 2016 The server should auto update when it is in idle mode and there isn't users logged in
mellomade 141 Posted October 25, 2016 Posted October 25, 2016 And they even force you to have automatic updates enabled even after you manually disable it!* * - this only happens when you turn off automatic upgrades and then update your server manually. After the update it is turned back on again. Grrr.....
ebr 15545 Posted October 25, 2016 Posted October 25, 2016 If talking about updates, this is already possible.
Pistolero 0 Posted October 25, 2016 Author Posted October 25, 2016 (edited) Hi all! Thank you for your replies! I run EmBy on a dedicated Windows 2012 R2 server as a service, so the auto update options do not appear for me. I wrote the following script to updte the server, but I still need to click to allow the setup file to run, so I cannot trigger it from a new version update and have it do its thing without a human present: @Echo Off REM Declaring variables set setup=%temp%\EmbyServerSetup.exe set url=http://embydata.com/downloads/server/release/setup.exe set EmBySvr=MediaBrowser.ServerApplication.exe set DashBoard=http://localhost:8096/web/dashboard.html del %setup% >NUL echo Stopping EmBy Server Service... Please wait... echo * echo * net stop EmBy >NUL ping -n 2 127.0.0.1>NUL start /wait /MIN sc stop EmBy >NUL start /wait /MIN taskkill /im %EmBySvr% /f /t >NUL ping -n 5 127.0.0.1>NUL echo * echo * echo Now downloading the latest build of the server setup app. Please wait... echo * echo * start /wait /MIN wget %url% --output-document=%setup% echo * echo * echo Now installing the new build. Please wait... start /wait %setup% echo * echo * ping -n 15 127.0.0.1>NUL GOTO CheckInst :CheckInst REM cmd /c exit /b 0 >NUL set inst=MediaBrowser.Server.Installer.exe echo Checking whether the setup process is still running. Please wait... ping -n 45 127.0.0.1>NUL TASKLIST /FO LIST | FINDSTR /I %inst% >NUL if ERRORLEVEL 1 ( echo Setup completed! GOTO CheckProc ) ELSE ( echo Setup process is still runnning. Please wait... ) GOTO CheckInst :CheckProc REM cmd /c exit /b 0 >NUL ping -n 30 127.0.0.1>NUL TASKLIST /FO LIST | FINDSTR /I %EmBySvr% >NUL if ERRORLEVEL 0 ( echo "Starting Service, please wait" GOTO StartSvc ) else ( echo Checking whether the EmBy process is running to kill it and start the service echo * echo EmBy Server Process is still runnning. Please wait... ) GOTO :CheckProc :StartSvc echo Starting EmBy service now. Please wait... start /wait /MIN taskkill /im %EmBySvr% /f /t >NUL ping -n 5 127.0.0.0>NUL net start EmBy >NUL ping -n 5 127.0.0.0>NUL start /wait /MIN sc start EmBy >NUL GOTO exit :EXIT TASKLIST /FO LIST | FINDSTR /I %EmBySvr% >NUL if ERRORLEVEL 1 ( echo "Starting Service please wait" GOTO StartSvc ) else ( echo Server successfully installed! Bye! ping -n 3 127.0.0.0>NUL start %DashBoard% del %setup% ) So, I think my showstopper is the setup program itself, which then downloads the actual EmBy bits and installs them: http://embydata.com/downloads/server/release/setup.exe Is there a switch I can use with this setup.exe to make it fully silent when executed, or, can I get the direct URL from where the actual bits are downloaded by it? BTW, please feel free to plagiarize my script if it'll work for you. And if you can make it better please share it back Edited October 25, 2016 by Pistolero
ebr 15545 Posted October 26, 2016 Posted October 26, 2016 You don't need to run the setup program each time. Do a search on this forum. There are already a couple of scripts posted out here to handle updates while running as a service. Or you could just run as a normal app under a user and it will be all automatic. 1
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now