mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
add amazonlinux DockerFile and related test changes
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
# Docker image file that describes an Centos7 image with PowerShell installed from Microsoft YUM Repo
|
||||
|
||||
FROM amazonlinux:latest
|
||||
|
||||
LABEL maintainer="PowerShell Team <powershellteam@hotmail.com>"
|
||||
LABEL readme.md="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md"
|
||||
LABEL description="This Dockerfile will install the latest release of PS."
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
# Install dependencies and clean up
|
||||
RUN yum install -y \
|
||||
curl \
|
||||
&& yum clean all
|
||||
|
||||
# Download and configure Microsoft Repository config file
|
||||
RUN curl https://packages.microsoft.com/config/rhel/7/prod.repo | tee /etc/yum.repos.d/microsoft.repo
|
||||
|
||||
# Install latest powershell from Microsoft YUM Repo
|
||||
RUN yum install -y \
|
||||
powershell
|
||||
|
||||
# Use PowerShell as the default shell
|
||||
# Use array to avoid Docker prepending /bin/sh -c
|
||||
CMD [ "powershell" ]
|
||||
@@ -65,7 +65,7 @@ function Invoke-Docker
|
||||
# Return a list of Linux Container Test Cases
|
||||
function Get-LinuxContainer
|
||||
{
|
||||
foreach($os in 'centos7','opensuse42.1','ubuntu14.04','ubuntu16.04')
|
||||
foreach($os in 'amazonlinux','centos7','opensuse42.1','ubuntu14.04','ubuntu16.04')
|
||||
{
|
||||
Write-Output @{
|
||||
Name = $os
|
||||
|
||||
Reference in New Issue
Block a user