GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — bashbrew/Dockerfile.release at master · docker-library/bashbrew

Expand file tree

/

Dockerfile.release

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
95 lines (85 loc) · 2.49 KB
/

Dockerfile.release

Copy path

File metadata and controls

95 lines (85 loc) · 2.49 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
FROM golang:1.24-trixie
SHELL ["bash", "-Eeuo", "pipefail", "-xc"]
RUN apt-get update; \
apt-get install -y --no-install-recommends \
file \
gnupg \
wget \
; \
apt-get dist-clean
WORKDIR /usr/src/bashbrew
ENV CGO_ENABLED 0
ENV BASHBREW_ARCHES \
amd64 \
arm32v5 \
arm32v6 \
arm32v7 \
arm64v8 \
darwin-amd64 \
i386 \
mips64le \
ppc64le \
riscv64 \
s390x \
windows-amd64
COPY scripts/bashbrew-arch-to-goenv.sh /usr/local/bin/
# https://github.com/estesp/manifest-tool/releases
ENV MANIFEST_TOOL_VERSION 1.0.2
# gpg: key 0F386284C03A1162: public key "Philip Estes <[email protected]>" imported
ENV MANIFEST_TOOL_GPG_KEY 27F3EA268A97867EAF0BD05C0F386284C03A1162
RUN export GNUPGHOME="$(mktemp -d)"; \
gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$MANIFEST_TOOL_GPG_KEY"; \
\
mkdir -p bin; \
\
for bashbrewArch in $BASHBREW_ARCHES; do \
# TODO convince estesp to release riscv64 binaries (https://github.com/estesp/manifest-tool/pull/113 👀)
if [ "$bashbrewArch" = 'riscv64' ]; then continue; fi; \
( \
goEnv="$(bashbrew-arch-to-goenv.sh "$bashbrewArch")"; eval "$goEnv"; \
srcBin="manifest-tool-$GOOS-$GOARCH"; \
if [ "$GOARCH" = 'arm' ]; then [ -n "$GOARM" ]; srcBin="${srcBin}v$GOARM"; fi; \
[ "$GOOS" = 'windows' ] && ext='.exe' || ext=; \
srcBin="$srcBin$ext"; \
targetBin="bin/manifest-tool-$bashbrewArch$ext"; \
wget -O "$targetBin.asc" "https://github.com/estesp/manifest-tool/releases/download/v${MANIFEST_TOOL_VERSION}/$srcBin.asc"; \
wget -O "$targetBin" "https://github.com/estesp/manifest-tool/releases/download/v${MANIFEST_TOOL_VERSION}/$srcBin" --progress=dot:giga; \
gpg --batch --verify "$targetBin.asc" "$targetBin"; \
ls -lAFh "$targetBin"*; \
file "$targetBin"*; \
) \
done; \
\
gpgconf --kill all; \
rm -r "$GNUPGHOME"; \
\
ls -lAFh bin/manifest-tool-*; \
file bin/manifest-tool-*
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN for bashbrewArch in $BASHBREW_ARCHES; do \
( \
goEnv="$(bashbrew-arch-to-goenv.sh "$bashbrewArch")"; eval "$goEnv"; \
[ "$GOOS" = 'windows' ] && ext='.exe' || ext=; \
\
LDFLAGS='-s -w'; \
case "$GOOS" in \
darwin | windows) ;; \
*) LDFLAGS+=' -d' ;; \
esac; \
\
targetBin="bin/bashbrew-$bashbrewArch$ext"; \
go build \
-v -ldflags "$LDFLAGS" \
-tags netgo -installsuffix netgo \
-o "$targetBin" \
./cmd/bashbrew \
; \
ls -lAFh "$targetBin"; \
file "$targetBin"; \
) \
done; \
\
ls -lAFh bin/bashbrew-*; \
file bin/bashbrew-*
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.