Package validation tests updates (#8714)
This commit is contained in:
parent
c955f313e4
commit
3bf8d34f58
|
@ -1,28 +0,0 @@
|
|||
FROM debian:jessie
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
# Install dependencies
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
apt-utils \
|
||||
ca-certificates \
|
||||
curl \
|
||||
apt-transport-https \
|
||||
locales \
|
||||
git
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN locale-gen $LANG && update-locale
|
||||
|
||||
RUN curl -L -o $PACKAGENAME $PACKAGELOCATION/$PACKAGENAME
|
||||
RUN dpkg -i $PACKAGENAME || :
|
||||
RUN apt-get install -y -f
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN pwsh$PREVIEWSUFFIX -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -1,26 +0,0 @@
|
|||
FROM fedora:26
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
# Install dependencies
|
||||
RUN dnf install -y \
|
||||
curl \
|
||||
glibc-locale-source \
|
||||
compat-openssl10 \
|
||||
git \
|
||||
&& dnf upgrade-minimal -y --security \
|
||||
&& dnf clean all
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
RUN curl -L -o $PACKAGENAME $PACKAGELOCATION/$PACKAGENAME
|
||||
RUN dnf install -y $PACKAGENAME
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN pwsh$PREVIEWSUFFIX -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -1,26 +0,0 @@
|
|||
FROM fedora:27
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
# Install dependencies
|
||||
RUN dnf install -y \
|
||||
curl \
|
||||
glibc-locale-source \
|
||||
git \
|
||||
compat-openssl10 \
|
||||
&& dnf upgrade-minimal -y --security \
|
||||
&& dnf clean all
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
RUN curl -L -o $PACKAGENAME $PACKAGELOCATION/$PACKAGENAME
|
||||
RUN dnf install -y $PACKAGENAME
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN pwsh$PREVIEWSUFFIX -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -1,4 +1,4 @@
|
|||
FROM microsoft/dotnet:2.1-runtime-stretch-slim
|
||||
FROM microsoft/dotnet:2.1.7-runtime-stretch-slim
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
|
|
|
@ -1,38 +0,0 @@
|
|||
FROM fedora:27
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
# Install dependencies
|
||||
RUN dnf install -y \
|
||||
glibc-locale-source \
|
||||
git \
|
||||
compat-openssl10 \
|
||||
&& dnf upgrade-minimal -y --security \
|
||||
&& dnf clean all
|
||||
|
||||
# Install dotnet-runtime
|
||||
RUN rpm --import https://packages.microsoft.com/keys/microsoft.asc
|
||||
ADD https://packages.microsoft.com/config/fedora/27/prod.repo .
|
||||
RUN mv prod.repo /etc/yum.repos.d/microsoft-prod.repo
|
||||
RUN dnf install -y \
|
||||
dotnet-runtime-2.1 \
|
||||
&& dnf upgrade-minimal -y --security \
|
||||
&& dnf clean all
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
# Install PowerShell package
|
||||
ADD $PACKAGELOCATION/$PACKAGENAME .
|
||||
RUN mkdir -p /opt/microsoft/powershell
|
||||
RUN tar zxf $PACKAGENAME -C /opt/microsoft/powershell
|
||||
|
||||
# Download and run tests
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN dotnet /opt/microsoft/powershell/pwsh.dll -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -1,40 +0,0 @@
|
|||
FROM opensuse:42.2
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
# Install dependencies
|
||||
RUN zypper --non-interactive update --skip-interactive \
|
||||
&& zypper --non-interactive install \
|
||||
glibc-locale \
|
||||
glibc-i18ndata \
|
||||
tar \
|
||||
libunwind \
|
||||
libicu \
|
||||
openssl \
|
||||
git
|
||||
|
||||
# Install dotnet-runtime
|
||||
RUN rpm --import https://packages.microsoft.com/keys/microsoft.asc
|
||||
ADD https://packages.microsoft.com/config/opensuse/42.2/prod.repo .
|
||||
RUN mv prod.repo /etc/zypp/repos.d/microsoft-prod.repo
|
||||
RUN zypper --non-interactive update --skip-interactive \
|
||||
&& zypper --non-interactive install \
|
||||
dotnet-runtime-2.1
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
# Install PowerShell package
|
||||
ADD $PACKAGELOCATION/$PACKAGENAME .
|
||||
RUN mkdir -p /opt/microsoft/powershell
|
||||
RUN tar zxf $PACKAGENAME -C /opt/microsoft/powershell
|
||||
|
||||
# Download and run tests
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN dotnet /opt/microsoft/powershell/pwsh.dll -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -18,7 +18,8 @@ RUN zypper --non-interactive update --skip-interactive \
|
|||
git
|
||||
|
||||
# Install dotnet-runtime
|
||||
RUN rpm --import https://packages.microsoft.com/keys/microsoft.asc
|
||||
ADD https://packages.microsoft.com/keys/microsoft.asc .
|
||||
RUN rpmkeys --import microsoft.asc
|
||||
ADD https://packages.microsoft.com/config/opensuse/42.2/prod.repo .
|
||||
RUN mv prod.repo /etc/zypp/repos.d/microsoft-prod.repo
|
||||
RUN zypper --non-interactive update --skip-interactive \
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
FROM microsoft/dotnet:2.1-runtime-bionic
|
||||
FROM microsoft/dotnet:2.1.7-runtime-bionic
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
|
|
|
@ -1,39 +0,0 @@
|
|||
FROM opensuse:42.2
|
||||
|
||||
ARG PACKAGENAME
|
||||
ARG PACKAGELOCATION
|
||||
ARG PREVIEWSUFFIX=
|
||||
ARG TESTLIST=/PowerShell/test/powershell/Modules/PackageManagement/PackageManagement.Tests.ps1,/PowerShell/test/powershell/engine/Module
|
||||
ARG TESTDOWNLOADCOMMAND="git clone --recursive https://github.com/PowerShell/PowerShell.git"
|
||||
|
||||
ARG POWERSHELL_LINKFILE=/usr/bin/pwsh
|
||||
|
||||
# Install dependencies
|
||||
RUN zypper --non-interactive update --skip-interactive \
|
||||
&& zypper --non-interactive install \
|
||||
glibc-locale \
|
||||
glibc-i18ndata \
|
||||
tar \
|
||||
curl \
|
||||
libunwind \
|
||||
libicu \
|
||||
openssl \
|
||||
git
|
||||
|
||||
# Setup the locale
|
||||
ENV LANG en_US.UTF-8
|
||||
ENV LC_ALL $LANG
|
||||
RUN localedef --charmap=UTF-8 --inputfile=en_US $LANG
|
||||
|
||||
RUN curl -L -o $PACKAGENAME $PACKAGELOCATION/$PACKAGENAME
|
||||
|
||||
# Create the target folder where powershell will be placed
|
||||
RUN mkdir -p /opt/microsoft/powershell
|
||||
# Expand powershell to the target folder
|
||||
RUN tar zxf $PACKAGENAME -C /opt/microsoft/powershell
|
||||
|
||||
# Create the symbolic link that points to powershell
|
||||
RUN ln -s /opt/microsoft/powershell/pwsh $POWERSHELL_LINKFILE
|
||||
|
||||
RUN $TESTDOWNLOADCOMMAND
|
||||
RUN pwsh -c "Import-Module /PowerShell/build.psm1;\$dir='/usr/local/share/powershell/Modules';\$null=New-Item -Type Directory -Path \$dir -ErrorAction SilentlyContinue;Restore-PSPester -Destination \$dir;exit (Invoke-Pester $TESTLIST -PassThru).FailedCount"
|
|
@ -221,19 +221,14 @@ function Get-DefaultPreviewConfigForPackageValidation
|
|||
# format: <DockerfileFolderName>=<PartOfPackageFilename>
|
||||
@{ 'centos7'='rhel.7';
|
||||
'debian.9'='debian.9';
|
||||
'fedora26'='rhel.7';
|
||||
'fedora27'='rhel.7';
|
||||
'fedora28'='rhel.7';
|
||||
'opensuse42.2'='linux-x64.tar.gz';
|
||||
'opensuse42.3'='linux-x64.tar.gz';
|
||||
'ubuntu14.04'='ubuntu.14.04';
|
||||
'ubuntu16.04'='ubuntu.16.04';
|
||||
'ubuntu18.04'='ubuntu.18.04';
|
||||
'fxdependent-centos7'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-debian.9'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-fedora27'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-fedora28'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-opensuse42.2'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-opensuse42.3'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-ubuntu14.04'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-ubuntu16.04'='linux-x64-fxdependent.tar.gz';
|
||||
|
@ -250,16 +245,11 @@ function Get-DefaultStableConfigForPackageValidation
|
|||
# format: <DockerfileFolderName>=<PartOfPackageFilename>
|
||||
@{ 'centos7'='rhel.7';
|
||||
'debian.9'='debian.9';
|
||||
'fedora26'='rhel.7';
|
||||
'fedora27'='rhel.7';
|
||||
'opensuse42.2'='linux-x64.tar.gz';
|
||||
'opensuse42.3'='linux-x64.tar.gz';
|
||||
'ubuntu14.04'='ubuntu.14.04';
|
||||
'ubuntu16.04'='ubuntu.16.04';
|
||||
'fxdependent-centos7'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-debian.9'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-fedora27'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-opensuse42.2'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-opensuse42.3'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-ubuntu14.04'='linux-x64-fxdependent.tar.gz';
|
||||
'fxdependent-ubuntu16.04'='linux-x64-fxdependent.tar.gz'
|
||||
|
|
Loading…
Reference in a new issue