summaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
authorChristian Segundo2022-12-05 17:00:08 +0100
committerChristian Segundo2022-12-05 22:16:11 +0100
commit061a5bae272f45db6dcde99746922735f9769d25 (patch)
treee4dd9b6d903930c5c1b76286b4a08beea6f59162 /Dockerfile
parent8817203517907ef4248bde7474e6fb566515d6a7 (diff)
downloadadvent-of-zig-2022-061a5bae272f45db6dcde99746922735f9769d25.tar.gz
add day 5
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile15
1 files changed, 15 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..adfd1ab
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,15 @@
+FROM alpine:3.16
+
+ARG ZIG_VERSION
+
+RUN apk update && \
+ apk --no-cache add \
+ curl \
+ make \
+ musl-dev \
+ libarchive-tools && \
+ if echo ${ZIG_VERSION} | grep -q "dev"; then PREFIX=builds; else PREFIX="download/${ZIG_VERSION}"; fi && \
+ curl -s \
+ https://ziglang.org/${PREFIX}/zig-linux-x86_64-${ZIG_VERSION}.tar.xz |\
+ bsdtar -x -f - && \
+ mv zig-linux-x86_64-${ZIG_VERSION}/* /usr/local/bin/