Last active
November 18, 2019 16:04
-
-
Save tresf/f116ade5560a4739d5af3a75d15d70b1 to your computer and use it in GitHub Desktop.
QZ Tray Service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REM ###### 1. Run the site to be using QZ Tray and click "Remember this decision" | |
REM ###### 2. Create a batch file that launches QZ Tray | |
echo java -Xms512M -jar "%~dp0\qz-tray.jar" %* > "%PROGRAMFILES%\QZ Tray\qz-tray.bat" | |
REM ###### 3. Make a location for SYSTEM certificate white-list | |
mkdir "%WINDIR%\System32\config\systemprofile\AppData\Roaming\qz" | |
REM ###### 4. Copy the "allowed.dat" to the SYSTEM | |
copy /Y "%APPDATA%\qz\allowed.dat" "%WINDIR%\System32\config\systemprofile\AppData\Roaming\qz\allowed.dat" | |
REM ###### 5. Install the service | |
nssm install "QZ Tray" "%PROGRAMFILES%\QZ Tray\qz-tray.bat" | |
nssm set "QZ Tray" Description "Browser printing utility" | |
REM ###### 6. Start the service | |
net start "QZ Tray" | |
REM ###### 99. Remove the service | |
REM net stop "QZ Tray" | |
REM nssm remove "QZ Tray" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment