10000 add amazonlinux DockerFile and related test changes · PowerShell/PowerShell@cea2024 · GitHub
[go: up one dir, main page]

Skip to content

Commit cea2024

Browse files
DarwinJSTravisEz13
authored andcommitted
add amazonlinux DockerFile and related test changes
1 parent 0150f65 commit cea2024

File tree

2 files changed

+29
-1
lines changed

2 files changed

+29
-1
lines changed

docker/release/amazonlinux/Dockerfile

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Docker image file that describes an Centos7 image with PowerShell installed from Microsoft YUM Repo
2+
3+
FROM amazonlinux:latest
4+
5+
LABEL maintainer="PowerShell Team <powershellteam@hotmail.com>"
6+
LABEL readme.md="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md"
7+
LABEL description="This Dockerfile will install the latest release of PS."
8+
9+
# Setup the locale
10+
ENV LANG en_US.UTF-8
11+
ENV LC_ALL $LANG
12+
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
13+
14+
# Install dependencies and clean up
15+
RUN yum install -y \
16+
curl \
17+
&& yum clean all
18+
19+
# Download and configure Microsoft Repository config file
20+
RUN curl https://packages.microsoft.com/config/rhel/7/prod.repo | tee /etc/yum.repos.d/microsoft.repo
21+
22+
# Install latest powershell from Microsoft YUM Repo
23+
RUN yum install -y \
24+
powershell
25+
26+
# Use PowerShell as the default shell
27+
# Use array to avoid Docker prepending /bin/sh -c
28+
CMD [ "powershell" ]

docker/tests/containerTestCommon.psm1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ function Invoke-Docker
6565
# Return a list of Linux Container Test Cases
6666
function Get-LinuxContainer
6767
{
68-
foreach($os in 'centos7','opensuse42.1','ubuntu14.04','ubuntu16.04')
68+
foreach($os in 'amazonlinux','centos7','opensuse42.1','ubuntu14.04','ubuntu16.04')
6969
{
7070
Write-Output @{
7171
Name = $os

0 commit comments

Comments
 (0)
0