My Favorite Ultra-VNC setup:
Not all issues can fixed from command line alas, thus this recipe:
uvnc:
file.recurse:
- source: salt://uvnc
- name: 'c:\salt\uvnc'
- makedirs: True
cmd.run:
- name: 'c:\salt\uvnc\state.cmd'
module.run:
- name: firewall.disable
remeber to re-enable the firewall of the client when finished. (salt "client" firewall.enable)
you will need to create uvnc folder (get it from UltraVNC portable builds) folder in your Salt master, in /srv/salt
in it :
winvnc.exe
UltraVNC.ini
state.cmd
SecureVNCPlugin32.dsm (Optional Encryption plugin)
Server_ClientAuth.pubkey (Optional Encryption server SSL handshake check)
And in the state.cmd put the following:
taskkill /f /im winvnc.exe
sc stop uvnc_service
sc delete uvnc_service
"c:\salt\uvnc\winvnc.exe" -install
"c:\salt\uvnc\winvnc.exe" -startservice
sc config uvnc_service start= demand
ipconfig | findstr /i "ipv4"
And whenever you want to connect to client, run this in salt master:
salt '172' state.apply uvnc
And you will see the IP of the client, you will need to match the IP and if you made any custom setting like port number/encryption plugin with vnc viewer and connect to client.