-
Notifications
You must be signed in to change notification settings - Fork 18
/
Dockerfile
25 lines (21 loc) · 921 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
FROM ubuntu:20.04
# install powershell for Ubuntu 20.04
RUN apt-get update \
&& apt-get install -y wget apt-transport-https software-properties-common \
&& wget -q https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb \
&& apt-get update \
# Register the Microsoft repository GPG keys
&& dpkg -i packages-microsoft-prod.deb \
# Update the list of products
&& add-apt-repository universe \
&& apt-get update \
&& apt-get install libssl-dev -y \
&& apt-get install gss-ntlmssp -y \
&& apt-get install powershell -y \
&& apt-get install curl -y \
&& apt-get install git -y
# install the module we need
RUN ["pwsh", "-Command", "Install-Module -name powershell-yaml -Scope AllUsers -Force -Repository PSGallery; ls opt/microsoft/powershell/7;"]
# check that the module is installed
RUN ls /root/.local/share/powershell/Modules
SHELL ["pwsh"]