Skip to content

Commit 99fe27b

Browse files
Enhancement: Add pwsh 7.4.0 variants
Signed-off-by: The Oh Brothers Bot <bot@theohbrothers.com>
1 parent da3671e commit 99fe27b

File tree

15 files changed

+670
-2
lines changed

15 files changed

+670
-2
lines changed

.github/workflows/ci-master-pr.yml

Lines changed: 458 additions & 1 deletion
Large diffs are not rendered by default.

README.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ Dockerized `powershell`, based on [mcr.microsoft.com/powershell](https://hub.doc
1010

1111
| Tag | Dockerfile Build Context |
1212
|:-------:|:---------:|
13+
| `:7.4-alpine-3.17` | [View](variants/7.4-alpine-3.17) |
14+
| `:7.4-alpine-3.17-git` | [View](variants/7.4-alpine-3.17-git) |
15+
| `:7.4-alpine-3.17-git-sops` | [View](variants/7.4-alpine-3.17-git-sops) |
1316
| `:7.3-alpine-3.17` | [View](variants/7.3-alpine-3.17) |
1417
| `:7.3-alpine-3.17-git` | [View](variants/7.3-alpine-3.17-git) |
1518
| `:7.3-alpine-3.17-git-sops` | [View](variants/7.3-alpine-3.17-git-sops) |
@@ -28,7 +31,10 @@ Dockerized `powershell`, based on [mcr.microsoft.com/powershell](https://hub.doc
2831
| `:6.1.3-alpine-3.8` | [View](variants/6.1.3-alpine-3.8) |
2932
| `:6.1.3-alpine-3.8-git` | [View](variants/6.1.3-alpine-3.8-git) |
3033
| `:6.1.3-alpine-3.8-git-sops` | [View](variants/6.1.3-alpine-3.8-git-sops) |
31-
| `:7.3-ubuntu-22.04`, `:latest` | [View](variants/7.3-ubuntu-22.04) |
34+
| `:7.4-ubuntu-22.04`, `:latest` | [View](variants/7.4-ubuntu-22.04) |
35+
| `:7.4-ubuntu-22.04-git` | [View](variants/7.4-ubuntu-22.04-git) |
36+
| `:7.4-ubuntu-22.04-git-sops` | [View](variants/7.4-ubuntu-22.04-git-sops) |
37+
| `:7.3-ubuntu-22.04` | [View](variants/7.3-ubuntu-22.04) |
3238
| `:7.3-ubuntu-22.04-git` | [View](variants/7.3-ubuntu-22.04-git) |
3339
| `:7.3-ubuntu-22.04-git-sops` | [View](variants/7.3-ubuntu-22.04-git-sops) |
3440
| `:7.2-ubuntu-22.04` | [View](variants/7.2-ubuntu-22.04) |

generate/definitions/versions.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"pwsh": {
33
"versions": [
4+
"7.4.0",
45
"7.3.10",
56
"7.2.17"
67
],
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
FROM mcr.microsoft.com/powershell:7.4-alpine-3.17
2+
3+
# Disable telemetry for powershell 7.0.0 and above and .NET core: https://github.com/PowerShell/PowerShell/issues/16234#issuecomment-942139350
4+
ENV POWERSHELL_CLI_TELEMETRY_OPTOUT=1
5+
ENV POWERSHELL_TELEMETRY_OPTOUT=1
6+
ENV POWERSHELL_UPDATECHECK=Off
7+
ENV POWERSHELL_UPDATECHECK_OPTOUT=1
8+
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1
9+
ENV DOTNET_TELEMETRY_OPTOUT=1
10+
ENV COMPlus_EnableDiagnostics=0
11+
12+
# Install Pester
13+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 4.0.0 -MaximumVersion 4.10.1 -Force -ErrorAction Stop -Verbose'
14+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 5.0.0 -Force -ErrorAction Stop -Verbose'
15+
16+
RUN apk add --no-cache git
17+
18+
RUN set -eux; \
19+
wget -qO- https://github.com/mozilla/sops/releases/download/v3.7.1/sops-v3.7.1.linux > /usr/local/bin/sops; \
20+
chmod +x /usr/local/bin/sops; \
21+
sha256sum /usr/local/bin/sops | grep '^185348fd77fc160d5bdf3cd20ecbc796163504fd3df196d7cb29000773657b74 '; \
22+
sops --version
23+
24+
RUN apk add --no-cache gnupg
25+
26+
COPY docker-entrypoint.sh /docker-entrypoint.sh
27+
RUN chmod +x docker-entrypoint.sh
28+
29+
ENTRYPOINT [ "/docker-entrypoint.sh" ]
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/bin/sh
2+
set -eu
3+
4+
if [ $# -gt 0 ] && [ "${1#-}" != "$1" ]; then
5+
set -- pwsh "$@"
6+
fi
7+
8+
exec "$@"
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
FROM mcr.microsoft.com/powershell:7.4-alpine-3.17
2+
3+
# Disable telemetry for powershell 7.0.0 and above and .NET core: https://github.com/PowerShell/PowerShell/issues/16234#issuecomment-942139350
4+
ENV POWERSHELL_CLI_TELEMETRY_OPTOUT=1
5+
ENV POWERSHELL_TELEMETRY_OPTOUT=1
6+
ENV POWERSHELL_UPDATECHECK=Off
7+
ENV POWERSHELL_UPDATECHECK_OPTOUT=1
8+
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1
9+
ENV DOTNET_TELEMETRY_OPTOUT=1
10+
ENV COMPlus_EnableDiagnostics=0
11+
12+
# Install Pester
13+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 4.0.0 -MaximumVersion 4.10.1 -Force -ErrorAction Stop -Verbose'
14+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 5.0.0 -Force -ErrorAction Stop -Verbose'
15+
16+
RUN apk add --no-cache git
17+
18+
COPY docker-entrypoint.sh /docker-entrypoint.sh
19+
RUN chmod +x docker-entrypoint.sh
20+
21+
ENTRYPOINT [ "/docker-entrypoint.sh" ]
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/bin/sh
2+
set -eu
3+
4+
if [ $# -gt 0 ] && [ "${1#-}" != "$1" ]; then
5+
set -- pwsh "$@"
6+
fi
7+
8+
exec "$@"
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM mcr.microsoft.com/powershell:7.4-alpine-3.17
2+
3+
# Disable telemetry for powershell 7.0.0 and above and .NET core: https://github.com/PowerShell/PowerShell/issues/16234#issuecomment-942139350
4+
ENV POWERSHELL_CLI_TELEMETRY_OPTOUT=1
5+
ENV POWERSHELL_TELEMETRY_OPTOUT=1
6+
ENV POWERSHELL_UPDATECHECK=Off
7+
ENV POWERSHELL_UPDATECHECK_OPTOUT=1
8+
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1
9+
ENV DOTNET_TELEMETRY_OPTOUT=1
10+
ENV COMPlus_EnableDiagnostics=0
11+
12+
# Install Pester
13+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 4.0.0 -MaximumVersion 4.10.1 -Force -ErrorAction Stop -Verbose'
14+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 5.0.0 -Force -ErrorAction Stop -Verbose'
15+
16+
COPY docker-entrypoint.sh /docker-entrypoint.sh
17+
RUN chmod +x docker-entrypoint.sh
18+
19+
ENTRYPOINT [ "/docker-entrypoint.sh" ]
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/bin/sh
2+
set -eu
3+
4+
if [ $# -gt 0 ] && [ "${1#-}" != "$1" ]; then
5+
set -- pwsh "$@"
6+
fi
7+
8+
exec "$@"
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
FROM mcr.microsoft.com/powershell:7.4-ubuntu-22.04
2+
3+
# Disable telemetry for powershell 7.0.0 and above and .NET core: https://github.com/PowerShell/PowerShell/issues/16234#issuecomment-942139350
4+
ENV POWERSHELL_CLI_TELEMETRY_OPTOUT=1
5+
ENV POWERSHELL_TELEMETRY_OPTOUT=1
6+
ENV POWERSHELL_UPDATECHECK=Off
7+
ENV POWERSHELL_UPDATECHECK_OPTOUT=1
8+
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1
9+
ENV DOTNET_TELEMETRY_OPTOUT=1
10+
ENV COMPlus_EnableDiagnostics=0
11+
12+
# Install Pester
13+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 4.0.0 -MaximumVersion 4.10.1 -Force -ErrorAction Stop -Verbose'
14+
RUN pwsh -c 'Install-Module Pester -Scope AllUsers -MinimumVersion 5.0.0 -Force -ErrorAction Stop -Verbose'
15+
16+
RUN set -eux; \
17+
apt-get update; \
18+
apt-get install -y git; \
19+
rm -rf /var/lib/apt/lists/*
20+
21+
# Install sops
22+
RUN set -eux; \
23+
buildDeps="wget"; \
24+
apt-get update; \
25+
apt-get install --no-install-recommends -y $buildDeps; \
26+
wget -qO- https://github.com/mozilla/sops/releases/download/v3.7.1/sops-v3.7.1.linux > /usr/local/bin/sops; \
27+
chmod +x /usr/local/bin/sops; \
28+
sha256sum /usr/local/bin/sops | grep '^185348fd77fc160d5bdf3cd20ecbc796163504fd3df196d7cb29000773657b74 '; \
29+
sops --version; \
30+
apt-get purge --auto-remove -y $buildDeps; \
31+
apt-get clean; \
32+
rm -rf /var/lib/apt/lists/*
33+
34+
# Install gnupg for sops
35+
RUN set -eux; \
36+
apt-get update; \
37+
apt-get install --no-install-recommends -y gnupg2; \
38+
apt-get clean; \
39+
rm -rf /var/lib/apt/lists/*
40+
41+
COPY docker-entrypoint.sh /docker-entrypoint.sh
42+
RUN chmod +x docker-entrypoint.sh
43+
44+
ENTRYPOINT [ "/docker-entrypoint.sh" ]

0 commit comments

Comments
 (0)