Automate WinSCP Deployment with ConfigMgr

This will automate the install of WinSCP and Disable Updates.

Create your Folder Structure:
\\ConfigMgrSourceServer\Apps\WinSCP\VersionNumber\
image

image

Download WinSCP here:https://winscp.net/eng/download.php

Scripts & Files available here: http://garytown.com/Downloads/WinSCP.zip
Download the EXE into the folder (Delete the blank place holder)

Create your Install & Uninstall Scripts:

Load_WinSCP.cmd Script:
-----------------------------

:paths
SET loc=%~dp0

REM Using FOR Loop to find any EXE file and run it with these arguments
for %%i in (*.exe) do cmd /c %%i  /VERYSILENT /NORESTART /LOADINF="%~dp0conf.inf" /NOCANDY /LOG="C:\InstallLogs\winscp.log"

REM Disable Updates
REG ADD "HKEY_LOCAL_MACHINE\SOFTWARE\Martin Prikryl\WinSCP 2" /v "DefaultUpdatesPeriod" /t REG_DWORD /d 00000000 /f

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

Uninstall_WinSCP.cmd
-------------------------

"C:\Program Files (x86)\WinSCP\unins000.exe" /SILENT

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

 

conf.inf file (Options selected for Silent Install)
--------------------------

[Setup]
Lang=en
Dir=C:\Program Files (x86)\WinSCP
Group=WinSCP
NoIcons=0
SetupType=full
Components=main,shellext,pageant,puttygen,transl,transl\eng
Tasks=desktopicon,desktopicon\common,sendtohook,urlhandler

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

I’m going to skip some of the pictures, and go right to the deployment type & detection methods, look at previous posts for a template to go from.

 

In the Content Tab, make sure it is pointing to your ConfigMgr Content Source.

 

image

 

For Detection Method, File System.  Each time it updates, I only have to change the Version Value, which makes it quite easy to update to the new version.
I have two detection methods, one for x86 machines and one for x64.  I’m showing the one for x64
image

That should do it.  You can now deploy the app.

As you can see, by setting that registry value in the install script, it sets the check for updates to NEVER
image

 

 

 

Happy Deployments!

One thought on “Automate WinSCP Deployment with ConfigMgr

Leave a Reply

Your email address will not be published. Required fields are marked *