-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support building Windows msi file #3999
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Binary file not shown.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
@echo off | ||
setlocal enableextensions | ||
|
||
title Podman | ||
|
||
:: If remote-host is given on command line -- use it | ||
setlocal enabledelayedexpansion | ||
for %%a in (%*) do ( | ||
echo "%%a" |find "--remote-host" >NUL | ||
if !errorlevel! == 0 ( | ||
goto run_podman | ||
) | ||
) | ||
|
||
:: If PODMAN_VARLINK_BRIDGE is set -- use it | ||
if defined PODMAN_VARLINK_BRIDGE ( | ||
goto run_podman | ||
) | ||
|
||
:: If the configuration file exists -- use it | ||
set config_home=%USERPROFILE%\AppData\podman | ||
set config_file=%config_home%\podman-remote.conf | ||
if exist "%config_file%" ( | ||
goto run_podman | ||
) | ||
|
||
:: Get connection information from user and build configuration file | ||
md "%config_home%" | ||
set /p host="Please enter the remote hosts name or IP address: " | ||
set /p user="Please enter the remote user name: " | ||
( | ||
echo [connections] | ||
echo [connections."%host%"] | ||
echo destination = "%host%" | ||
echo username = "%user%" | ||
echo default = true | ||
) >"%config_file%" | ||
|
||
:run_podman | ||
endlocal | ||
podman-remote-windows.exe %* | ||
|
||
:End |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> | ||
|
||
<?ifndef var.VERSION?> | ||
<?error VERSION must be defined via command line argument?> | ||
<?endif?> | ||
|
||
<Product Name="Podman $(var.VERSION)" Id="*" UpgradeCode="696BAB5D-CA1F-4B05-B123-320F245B8D6D" Version="$(var.VERSION)" Language="1033" Manufacturer="Red Hat Inc."> | ||
|
||
<Package Id="*" Keywords="Installer" Description="Red Hat's Podman $(var.VERSION) Installer" Comments="Apache 2.0 License" Manufacturer="Red Hat Inc." InstallScope="perMachine" InstallerVersion="100" Compressed="yes"/> | ||
<Media Id="1" Cabinet="Podman.cab" EmbedCab="yes"/> | ||
<Property Id="DiskPrompt" Value="Red Hat's Podman $(var.VERSION) Installation"/> | ||
|
||
<Directory Id="TARGETDIR" Name="SourceDir"> | ||
|
||
<Directory Id="ProgramFilesFolder" Name="PFiles"> | ||
<Directory Id="RedHatPFiles" Name="RedHat"> | ||
<Directory Id="INSTALLDIR" Name="Podman"> | ||
<Component Id="INSTALLDIR_Component" Guid="14B310C4-9B5D-4DA5-ADF9-B9D008E4CD82"> | ||
<CreateFolder/> | ||
</Component> | ||
<Component Id="MainExecutable" Guid="73752F94-6589-4C7B-ABED-39D655A19714"> | ||
<File Id="520C6E17-77A2-4F41-9611-30FA763A0702" Name="podman-remote-windows.exe" Source="bin/podman-remote-windows.exe"/> | ||
<File Id="A14218A0-4180-44AC-B109-7C63B3099DCA" Name="podman.bat" Source="podman.bat" KeyPath="yes"/> | ||
</Component> | ||
</Directory> | ||
</Directory> | ||
</Directory> | ||
</Directory> | ||
|
||
<Property Id="setx" Value="setx.exe"/> | ||
<CustomAction Id="ChangePath" ExeCommand='PATH "%PATH%;[INSTALLDIR]"' Property="setx" Execute="deferred" Impersonate="yes" Return="check"/> | ||
|
||
<Feature Id="Complete" Level="1"> | ||
<ComponentRef Id="INSTALLDIR_Component"/> | ||
<ComponentRef Id="MainExecutable"/> | ||
</Feature> | ||
|
||
<Icon Id="podman.ico" SourceFile="contrib/msi/podman-logo.ico"/> | ||
<Property Id="ARPPRODUCTICON" Value="podman.ico"/> | ||
|
||
<InstallExecuteSequence> | ||
<RemoveExistingProducts Before="InstallInitialize"/> | ||
<Custom Action="ChangePath" After="InstallServices">NOT Installed</Custom> | ||
</InstallExecuteSequence> | ||
|
||
</Product> | ||
</Wix> |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noticed that this doesn't cleanup the PATH on uninstall. Seems a bit dodgy to try to do that actually, but mentioning in case you know a clean way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you open a fresh issue about this? We don't actively review two-year-old closed PRs so this will get lost otherwise
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
np thanks for offering it issue worthy! #11089