Skip to content

How to prevent the "choco install" command to not copy the MSI file to temp. #3494

Closed Answered by AdmiringWorm
abhishekm1359 asked this question in Q&A
Discussion options

You must be logged in to vote

From the sounds of it, and since I assume this is a custom package that you have control over.

It sounds like you are using the cmdlet Install-ChocolateyPackage inside of the chocolateyInstall script.
This script is intended to be used when needing to download a remote file from the web, and will always download it to a temporary location, which it will also do if you specify a path on the local file system.

Instead of using Install-ChocolateyPackage for local files, you should instead make use of the cmdlet Install-ChocolateyInstallPackage which is intended to be used for local executables.
This won't download or copy anything to the temp directory, but rather run the passed in file (or f…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@abhishekm1359
Comment options

Answer selected by abhishekm1359
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants