Skip to content

Commit 401b436

Browse files
authored
fix: add bash to published base images (#78)
Mise-based tool installation relies on bash via ruby-build and similar tooling. Install bash in the shared base-image variants so standard cleanroom images can support repo-managed provisioning without a custom overlay.
1 parent 3cbd5c6 commit 401b436

File tree

4 files changed

+34
-0
lines changed

4 files changed

+34
-0
lines changed

images/Dockerfile.base-image

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
FROM alpine:3.22
22

33
RUN apk add --no-cache \
4+
bash \
45
git \
56
strace \
67
mise

images/Dockerfile.base-image-agents

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ ARG GEMINI_CLI_VERSION=0.31.0
66

77
# `gemini` currently needs native build deps on Alpine and GNU `env` for `env -S`.
88
RUN apk add --no-cache \
9+
bash \
910
coreutils \
1011
g++ \
1112
git \

images/Dockerfile.base-image-docker

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
FROM alpine:3.22
22

33
RUN apk add --no-cache \
4+
bash \
45
docker \
56
git \
67
strace \

images/dockerfiles_test.go

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
package images_test
2+
3+
import (
4+
"os"
5+
"path/filepath"
6+
"strings"
7+
"testing"
8+
)
9+
10+
func TestPublishedBaseImagesInstallBash(t *testing.T) {
11+
t.Parallel()
12+
13+
for _, relPath := range []string{
14+
"Dockerfile.base-image",
15+
"Dockerfile.base-image-docker",
16+
"Dockerfile.base-image-agents",
17+
} {
18+
relPath := relPath
19+
t.Run(relPath, func(t *testing.T) {
20+
t.Parallel()
21+
22+
raw, err := os.ReadFile(filepath.Join(".", relPath))
23+
if err != nil {
24+
t.Fatalf("read %s: %v", relPath, err)
25+
}
26+
if !strings.Contains(string(raw), "\n bash \\\n") {
27+
t.Fatalf("%s does not install bash", relPath)
28+
}
29+
})
30+
}
31+
}

0 commit comments

Comments
 (0)