.
This commit is contained in:
@ -9,6 +9,7 @@ mkdir %PACKAGES%
|
|||||||
|
|
||||||
call %WPUBLIC%\bin\SpeedUpPS.bat
|
call %WPUBLIC%\bin\SpeedUpPS.bat
|
||||||
|
|
||||||
|
echo "------- attempting uninstall first"
|
||||||
set PSFILE="C:\Program Files\OpenSSH\uninstall-sshd.ps1"
|
set PSFILE="C:\Program Files\OpenSSH\uninstall-sshd.ps1"
|
||||||
if exist %PSFILE% (
|
if exist %PSFILE% (
|
||||||
echo "SSH uninstall script"
|
echo "SSH uninstall script"
|
||||||
@ -24,24 +25,26 @@ rmdir /s/q "C:\Packages\openssh-portable-9.2.2.0"
|
|||||||
del /f/s/q "C:\Packages\OpenSSH-Win64\*.*"
|
del /f/s/q "C:\Packages\OpenSSH-Win64\*.*"
|
||||||
rmdir /s/q "C:\Packages\OpenSSH-Win64"
|
rmdir /s/q "C:\Packages\OpenSSH-Win64"
|
||||||
|
|
||||||
echo "Download and unpack OpenSSH"
|
echo "------- Download and unpack OpenSSH"
|
||||||
set PSFILE="%WPUBLIC%\bin\Download.ps1"
|
set PSFILE="%WPUBLIC%\bin\Download.ps1"
|
||||||
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
||||||
|
|
||||||
if exist "C:\Program Files\OpenSSH\sshd.exe" (
|
@REM if exist "C:\Program Files\OpenSSH\sshd.exe" (
|
||||||
echo "OPENSSH already installed"
|
@REM echo "OPENSSH already installed"
|
||||||
)
|
@REM )
|
||||||
else (
|
@REM else (
|
||||||
echo "NEW installation"
|
echo "NEW installation"
|
||||||
robocopy "%PACKAGES%\OpenSSH-Win64" "C:\Program Files\OpenSSH" /E
|
robocopy "%PACKAGES%\OpenSSH-Win64" "C:\Program Files\OpenSSH" /E
|
||||||
)
|
@REM )
|
||||||
|
|
||||||
|
echo "------- attempting install"
|
||||||
set PSFILE="C:\Program Files\OpenSSH\install-sshd.ps1"
|
set PSFILE="C:\Program Files\OpenSSH\install-sshd.ps1"
|
||||||
if exist %PSFILE% (
|
if exist %PSFILE% (
|
||||||
echo "SSH install script"
|
echo "SSH install script"
|
||||||
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
||||||
)
|
)
|
||||||
|
|
||||||
|
echo "------- fix firewall"
|
||||||
set PSFILE="%WPUBLIC%\bin\Firewall.ps1"
|
set PSFILE="%WPUBLIC%\bin\Firewall.ps1"
|
||||||
if exist %PSFILE% (
|
if exist %PSFILE% (
|
||||||
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
Powershell.exe -ExecutionPolicy Bypass -File %PSFILE%
|
||||||
|
|||||||
Reference in New Issue
Block a user