File tree 2 files changed +11
-3
lines changed
2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -12,9 +12,6 @@ RUN apk add --no-cache \
12
12
bash \
13
13
git \
14
14
openssh-client && \
15
- # Use the edge repo, since Terraform doesn't seem to be backported to 3.18.
16
- apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community \
17
- terraform=~1.5 && \
18
15
addgroup \
19
16
-g 1000 \
20
17
coder && \
@@ -25,6 +22,15 @@ RUN apk add --no-cache \
25
22
-u 1000 \
26
23
-G coder \
27
24
coder
25
+ # Terraform was disabled in the edge repo due to a build issue.
26
+ # https://gitlab.alpinelinux.org/alpine/aports/-/commit/f3e263d94cfac02d594bef83790c280e045eba35
27
+ # Using wget for now. Note that busybox unzip doesn't support streaming.
28
+ ARG ARCH
29
+ RUN wget -O /tmp/terraform.zip "https://releases.hashicorp.com/terraform/1.5.6/terraform_1.5.6_linux_${ARCH}.zip" && \
30
+ busybox unzip /tmp/terraform.zip -d /usr/local/bin && \
31
+ rm -f /tmp/terraform.zip && \
32
+ chmod +x /usr/local/bin/terraform && \
33
+ terraform --version
28
34
29
35
USER 1000:1000
30
36
ENV HOME=/home/coder
Original file line number Diff line number Diff line change @@ -103,6 +103,7 @@ declare -A arch_map=(
103
103
[arm]=" linux/arm/v7"
104
104
[armv7]=" linux/arm/v7"
105
105
)
106
+ orig_arch=" $arch "
106
107
if [[ " ${arch_map[$arch]+exists} " != " " ]]; then
107
108
arch=" ${arch_map[$arch]} "
108
109
fi
@@ -124,6 +125,7 @@ if [[ "$build_base" != "" ]]; then
124
125
log " --- Building base Docker image for $arch ($build_base )"
125
126
docker build \
126
127
--platform " $arch " \
128
+ --build-arg " ARCH=${orig_arch} " \
127
129
--tag " $build_base " \
128
130
--no-cache \
129
131
-f Dockerfile.base \
You can’t perform that action at this time.
0 commit comments