-
Notifications
You must be signed in to change notification settings - Fork 155
Bump alpine from 3.8 to 3.10.0 in /release/preview/alpine/dependabot #244
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
TravisEz13
merged 8 commits into
master
from
dependabot/docker/release/preview/alpine/dependabot/alpine-3.10.0
Jul 8, 2019
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
bf91520
Bump alpine from 3.8 to 3.10.0 in /release/preview/alpine/dependabot
dependabot-preview[bot] 4fc7bc2
update dependabot
TravisEz13 24da76c
add alpine 3.9 and 3.10
TravisEz13 e96f304
correct comments
TravisEz13 0d66a5a
fix from tags
TravisEz13 52cf256
make job names unique
TravisEz13 7f68906
Make YAML order consistent
TravisEz13 01f3af6
address PR feedback
TravisEz13 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
6 changes: 3 additions & 3 deletions
6
release/preview/alpine/getLatestTag.ps1 → release/preview/alpine38/getLatestTag.ps1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. | ||
|
||
# return objects representing the tags we need to base the xenial image on | ||
# return objects representing the tags we need to base the Alpine image on | ||
|
||
# The versions of xenial we care about | ||
# The versions of Alpine we care about, for this dockerfile | ||
$shortTags = @('3.8') | ||
|
||
$parent = Join-Path -Path $PSScriptRoot -ChildPath '..' | ||
$repoRoot = Join-Path -path (Join-Path -Path $parent -ChildPath '..') -ChildPath '..' | ||
$modulePath = Join-Path -Path $repoRoot -ChildPath 'tools\getDockerTags' | ||
Import-Module $modulePath | ||
|
||
Get-DockerTags -ShortTags $shortTags -Image "alpine" -FullTagFilter '^3.8$' -OnlyShortTags | ||
Get-DockerTags -ShortTags $shortTags -Image "alpine" -FullTagFilter '^3.\d$' -OnlyShortTags |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,4 @@ | |
|
||
# Dummy docker image to trigger dependabot PRs | ||
|
||
FROM alpine:3.8 | ||
FROM alpine:3.10.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. | ||
|
||
# Docker image file that describes an Alpine3.x image with PowerShell installed from .tar.gz file(s) | ||
|
||
# Define arg(s) needed for the From statement | ||
ARG fromTag=3.9 | ||
ARG imageRepo=alpine | ||
|
||
FROM ${imageRepo}:${fromTag} AS installer-env | ||
|
||
# Define Args for the needed to add the package | ||
ARG PS_VERSION=6.2.0-preview.3 | ||
ARG PS_PACKAGE=powershell-${PS_VERSION}-linux-alpine-x64.tar.gz | ||
ARG PS_PACKAGE_URL=https://github.com/PowerShell/PowerShell/releases/download/v${PS_VERSION}/${PS_PACKAGE} | ||
ARG PS_INSTALL_VERSION=7-preview | ||
|
||
# Download the Linux tar.gz and save it | ||
ADD ${PS_PACKAGE_URL} /tmp/linux.tar.gz | ||
|
||
# define the folder we will be installing PowerShell to | ||
ENV PS_INSTALL_FOLDER=/opt/microsoft/powershell/$PS_INSTALL_VERSION | ||
|
||
# Create the install folder | ||
RUN mkdir -p ${PS_INSTALL_FOLDER} | ||
|
||
# Unzip the Linux tar.gz | ||
RUN tar zxf /tmp/linux.tar.gz -C ${PS_INSTALL_FOLDER} | ||
|
||
# Start a new stage so we lose all the tar.gz layers from the final image | ||
FROM ${imageRepo}:${fromTag} | ||
|
||
# Copy only the files we need from the previous stage | ||
COPY --from=installer-env ["/opt/microsoft/powershell", "/opt/microsoft/powershell"] | ||
|
||
# Define Args and Env needed to create links | ||
ARG PS_INSTALL_VERSION=7-preview | ||
ENV PS_INSTALL_FOLDER=/opt/microsoft/powershell/$PS_INSTALL_VERSION \ | ||
\ | ||
# Define ENVs for Localization/Globalization | ||
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false \ | ||
LC_ALL=en_US.UTF-8 \ | ||
LANG=en_US.UTF-8 \ | ||
# set a fixed location for the Module analysis cache | ||
PSModuleAnalysisCachePath=/var/cache/microsoft/powershell/PSModuleAnalysisCache/ModuleAnalysisCache | ||
|
||
# Install dotnet dependencies and ca-certificates | ||
RUN apk add --no-cache \ | ||
ca-certificates \ | ||
less \ | ||
\ | ||
# PSReadline/console dependencies | ||
ncurses-terminfo-base \ | ||
\ | ||
# .NET Core dependencies | ||
krb5-libs \ | ||
libgcc \ | ||
libintl \ | ||
libssl1.1 \ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is the only line that changed |
||
libstdc++ \ | ||
tzdata \ | ||
userspace-rcu \ | ||
zlib \ | ||
icu-libs \ | ||
&& apk -X https://dl-cdn.alpinelinux.org/alpine/edge/main add --no-cache \ | ||
lttng-ust \ | ||
\ | ||
# Create the pwsh symbolic link that points to powershell | ||
&& ln -s ${PS_INSTALL_FOLDER}/pwsh /usr/bin/pwsh \ | ||
\ | ||
# Create the pwsh-preview symbolic link that points to powershell | ||
&& ln -s ${PS_INSTALL_FOLDER}/pwsh /usr/bin/pwsh-preview \ | ||
# Give all user execute permissions and remove write permissions for others | ||
&& chmod a+x,o-w ${PS_INSTALL_FOLDER}/pwsh \ | ||
# intialize powershell module cache | ||
&& pwsh \ | ||
-NoLogo \ | ||
-NoProfile \ | ||
-Command " \ | ||
\$ErrorActionPreference = 'Stop' ; \ | ||
\$ProgressPreference = 'SilentlyContinue' ; \ | ||
while(!(Test-Path -Path \$env:PSModuleAnalysisCachePath)) { \ | ||
Write-Host "'Waiting for $env:PSModuleAnalysisCachePath'" ; \ | ||
Start-Sleep -Seconds 6 ; \ | ||
}" | ||
|
||
# Define args needed only for the labels | ||
ARG PS_VERSION=6.2.0-preview.2 | ||
ARG IMAGE_NAME=mcr.microsoft.com/powershell:preview-alpine-3.8 | ||
ARG VCS_REF="none" | ||
|
||
# Add label last as it's just metadata and uses a lot of parameters | ||
LABEL maintainer="PowerShell Team <powershellteam@hotmail.com>" \ | ||
readme.md="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md" \ | ||
description="This Dockerfile will install the latest release of PowerShell." \ | ||
org.label-schema.usage="https://github.com/PowerShell/PowerShell/tree/master/docker#run-the-docker-image-you-built" \ | ||
org.label-schema.url="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md" \ | ||
org.label-schema.vcs-url="https://github.com/PowerShell/PowerShell-Docker" \ | ||
org.label-schema.name="powershell" \ | ||
org.label-schema.vendor="PowerShell" \ | ||
org.label-schema.vcs-ref=${VCS_REF} \ | ||
org.label-schema.version=${PS_VERSION} \ | ||
org.label-schema.schema-version="1.0" \ | ||
org.label-schema.docker.cmd="docker run ${IMAGE_NAME} pwsh -c '$psversiontable'" \ | ||
org.label-schema.docker.cmd.devel="docker run ${IMAGE_NAME}" \ | ||
org.label-schema.docker.cmd.test="docker run ${IMAGE_NAME} pwsh -c Invoke-Pester" \ | ||
org.label-schema.docker.cmd.help="docker run ${IMAGE_NAME} pwsh -c Get-Help" | ||
|
||
CMD [ "pwsh" ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. | ||
|
||
# return objects representing the tags we need to base the Alpine image on | ||
|
||
# The versions of Alpine we care about, for this dockerfile | ||
$shortTags = @('3.9','3.10') | ||
|
||
$parent = Join-Path -Path $PSScriptRoot -ChildPath '..' | ||
$repoRoot = Join-Path -path (Join-Path -Path $parent -ChildPath '..') -ChildPath '..' | ||
$modulePath = Join-Path -Path $repoRoot -ChildPath 'tools\getDockerTags' | ||
Import-Module $modulePath | ||
|
||
Get-DockerTags -ShortTags $shortTags -Image "alpine" -FullTagFilter '^3.\d\d?$' -OnlyShortTags |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"IsLinux" : true, | ||
"UseLinuxVersion": false, | ||
"PackageFormat": "powershell-${PS_VERSION}-linux-alpine-x64.tar.gz", | ||
"osVersion": "Alpine", | ||
"tagTemplates": [ | ||
"#psversion#-alpine-#tag#", | ||
"preview-alpine-#shorttag#" | ||
], | ||
"SkipGssNtlmSspTests": true, | ||
"SubImage": "test-deps", | ||
"TestProperties": { | ||
"size": 165 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# Docker image file that describes an Alpine image with PowerShell and test dependencies | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no changes in this file |
||
ARG BaseImage=mcr.microsoft.com/powershell:alpine-3.9 | ||
|
||
FROM node:10.15.3-alpine as node | ||
|
||
# Do nothing, just added to borrow the already built node files. | ||
|
||
FROM ${BaseImage} | ||
|
||
ENV NODE_VERSION 10.15.3 | ||
ENV YARN_VERSION=1.13.0 | ||
ENV NVM_DIR="/root/.nvm" | ||
|
||
# workaround for Alpine to run in Azure DevOps | ||
ENV NODE_NO_WARNINGS=1 | ||
|
||
# Copy node and yarn into image | ||
COPY --from=node /usr/local/bin/node /usr/local/bin/node | ||
COPY --from=node /opt/yarn-v${YARN_VERSION} /opt/yarn-v${YARN_VERSION} | ||
|
||
RUN apk add --no-cache --virtual .pipeline-deps readline linux-pam \ | ||
&& apk add \ | ||
bash \ | ||
sudo \ | ||
shadow \ | ||
openssl \ | ||
curl \ | ||
&& apk del .pipeline-deps \ | ||
&& ln -s /opt/yarn-v$YARN_VERSION/bin/yarn /usr/local/bin/yarn \ | ||
&& ln -s /opt/yarn-v$YARN_VERSION/bin/yarnpkg /usr/local/bin/yarnpkg | ||
|
||
# Define args needed only for the labels | ||
ARG VCS_REF="none" | ||
ARG IMAGE_NAME=mcr.microsoft.com/powershell/test-deps:alpine-3.8 | ||
ARG PS_VERSION=6.2.0 | ||
|
||
LABEL maintainer="PowerShell Team <powershellteam@hotmail.com>" \ | ||
readme.md="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md" \ | ||
description="This Dockerfile will install the latest release of PowerShell and tools needed for runing CI/CD container jobs." \ | ||
org.label-schema.usage="https://github.com/PowerShell/PowerShell/tree/master/docker#run-the-docker-image-you-built" \ | ||
org.label-schema.url="https://github.com/PowerShell/PowerShell/blob/master/docker/README.md" \ | ||
org.label-schema.vcs-url="https://github.com/PowerShell/PowerShell-Docker" \ | ||
org.label-schema.name="powershell" \ | ||
org.label-schema.vendor="PowerShell" \ | ||
org.label-schema.version=${PS_VERSION} \ | ||
org.label-schema.schema-version="1.0" \ | ||
org.label-schema.vcs-ref=${VCS_REF} \ | ||
org.label-schema.docker.cmd="docker run ${IMAGE_NAME} pwsh -c '$psversiontable'" \ | ||
org.label-schema.docker.cmd.devel="docker run ${IMAGE_NAME}" \ | ||
org.label-schema.docker.cmd.test="docker run ${IMAGE_NAME} pwsh -c Invoke-Pester" \ | ||
org.label-schema.docker.cmd.help="docker run ${IMAGE_NAME} pwsh -c Get-Help" \ | ||
com.azure.dev.pipelines.agent.handler.node.path="/usr/local/bin/node" | ||
|
||
# Use PowerShell as the default shell | ||
# Use array to avoid Docker prepending /bin/sh -c | ||
CMD [ "pwsh" ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"IsLinux" : true, | ||
"UseLinuxVersion": false, | ||
"SkipGssNtlmSspTests": true, | ||
"osVersion": "Alpine ${fromTag}", | ||
"tagTemplates": [ | ||
"preview-alpine-#shorttag#" | ||
], | ||
"OptionalTests": [ | ||
"test-deps", | ||
"test-deps-musl" | ||
], | ||
"TestProperties": { | ||
"size": 212 | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.