-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use smaller windows base image (#12)
- Loading branch information
1 parent
eee7570
commit dc3a21d
Showing
3 changed files
with
22 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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,12 +1,21 @@ | ||
# escape=` | ||
|
||
FROM mcr.microsoft.com/windows/servercore:1809 | ||
FROM mcr.microsoft.com/windows/servercore:1809 as base | ||
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] | ||
USER ContainerAdministrator | ||
|
||
ENV GODEBUG=netdns=go | ||
RUN mkdir /bin | ||
RUN Invoke-WebRequest https://releases.jfrog.io/artifactory/jfrog-cli/v2/2.10.0/jfrog-cli-windows-amd64/jfrog.exe -OutFile C:/bin/jfrog.exe | ||
|
||
FROM mcr.microsoft.com/powershell:nanoserver-1809 | ||
COPY --from=base /bin /bin | ||
|
||
ADD release/windows/amd64/plugin C:/bin/drone-artifactory.exe | ||
|
||
# https://github.com/PowerShell/PowerShell/issues/6211#issuecomment-367477137 | ||
USER ContainerAdministrator | ||
RUN setx /M PATH "%PATH%;C:\Program Files\PowerShell" | ||
|
||
SHELL ["pwsh", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] | ||
ENTRYPOINT [ "C:\\bin\\drone-artifactory.exe" ] |
This file contains 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,11 +1,21 @@ | ||
# escape=` | ||
FROM mcr.microsoft.com/windows/servercore:1909 | ||
|
||
FROM mcr.microsoft.com/windows/servercore:1909 as base | ||
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] | ||
USER ContainerAdministrator | ||
|
||
ENV GODEBUG=netdns=go | ||
RUN mkdir /bin | ||
RUN Invoke-WebRequest https://releases.jfrog.io/artifactory/jfrog-cli/v2/2.10.0/jfrog-cli-windows-amd64/jfrog.exe -OutFile C:/bin/jfrog.exe | ||
|
||
FROM mcr.microsoft.com/powershell:nanoserver-1909 | ||
COPY --from=base /bin /bin | ||
|
||
ADD release/windows/amd64/plugin C:/bin/drone-artifactory.exe | ||
|
||
# https://github.com/PowerShell/PowerShell/issues/6211#issuecomment-367477137 | ||
USER ContainerAdministrator | ||
RUN setx /M PATH "%PATH%;C:\Program Files\PowerShell" | ||
|
||
SHELL ["pwsh", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] | ||
ENTRYPOINT [ "C:\\bin\\drone-artifactory.exe" ] |
This file contains 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