microsoft/Docker-PowerShell

--build-args

Plork opened this issue · 4 comments

Plork commented

Output of ipmo Docker; (module Docker).Version.ToString() (from a powershell process):

0.1.0.111

New-ContainerImage does not have an option to provide "build time" arguments. for example:

docker build -t container --build-arg https_proxy=http://proxy:3128 .\container

Same goes for the Start-Container and all other cmdlets. To provide runtime environment variables or build time ones does not exist at the moment.

@Plork - Took a look at this. It looks like by just exposing the ImageBuildArgs as an additional parameter set you would be able to do this. Want to take a shot at contributing it?

Plork commented

Well I only know Powershell and a bit of Python and no C# tho ;)

Ok :) I will see if we cant add this for ya

Would that accept a hashtable or just be a string consisting of key value pairs separated by spaces?

The former would be more PowerShell-like.