mirror of
https://github.com/rapid7/metasploitable3.git
synced 2024-06-16 10:04:12 +02:00
only download 7z if missing
This commit is contained in:
parent
8d5ad5ae9b
commit
cec1d4395d
|
@ -1,7 +1,7 @@
|
|||
if not exist "C:\Windows\Temp\7zInstaller-x64.msi" (
|
||||
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('http://www.7-zip.org/a/7z1604-x64.msi', 'C:\Windows\Temp\7zInstaller-x64.msi')" <NUL
|
||||
if not exist "C:\Program Files\7-Zip\7z.exe" (
|
||||
powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; (New-Object System.Net.WebClient).DownloadFile('https://www.7-zip.org/a/7z1604-x64.msi', 'C:\Windows\Temp\7zInstaller-x64.msi')" <NUL
|
||||
msiexec /qb /i C:\Windows\Temp\7zInstaller-x64.msi
|
||||
)
|
||||
msiexec /qb /i C:\Windows\Temp\7zInstaller-x64.msi
|
||||
|
||||
if "%PACKER_BUILDER_TYPE%" equ "vmware-iso" goto :vmware
|
||||
if "%PACKER_BUILDER_TYPE%" equ "virtualbox-iso" goto :virtualbox
|
||||
|
@ -43,4 +43,6 @@ if exist "C:\Users\vagrant\prl-tools-win.iso" (
|
|||
)
|
||||
|
||||
:done
|
||||
msiexec /qb /x C:\Windows\Temp\7zInstaller-x64.msi
|
||||
if exist "C:\Windows\Temp\7zInstaller-x64.msi" (
|
||||
msiexec /qb /x C:\Windows\Temp\7zInstaller-x64.msi
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue
Block a user