Skip to content

Commit c63d4d2

Browse files
committed
- adds an argument and a condition to be able to pull a specific version of the module
1 parent e297f87 commit c63d4d2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
FROM mcr.microsoft.com/powershell
22

3-
RUN pwsh -c "Install-Module Microsoft.Graph -Scope CurrentUser -AllowClobber -Force "
3+
ARG MODULE_VERSION=latest
4+
5+
RUN pwsh -c "if ('${MODULE_VERSION}' -eq 'latest') { Install-Module Microsoft.Graph -Scope CurrentUser -AllowClobber -Force} else { Install-Module Microsoft.Graph -Scope CurrentUser -AllowClobber -Force -Version ${MODULE_VERSION} }"
46

57
LABEL description="# Welcome to Microsoft Graph PowrShell \
68
To start learning about the module checkout the [getting started documentation](https://docs.microsoft.com/en-us/powershell/microsoftgraph/get-started)"

0 commit comments

Comments
 (0)