Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
dazz committed Jul 31, 2024
0 parents commit 482972a
Show file tree
Hide file tree
Showing 6 changed files with 724 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.git
.gitignore
.github
README.md
LICENSE
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.idea
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM alpine:3

ENV S6_PATH=/s6/root

ARG TARGETARCH
ARG TARGETVARIANT
ARG S6_RELEASE

RUN apk add --no-cache curl jq \
&& if [ -z ${S6_RELEASE} ]; then \
S6_RELEASE=$(curl -s https://api.github.com/repos/just-containers/s6-overlay/releases/latest | jq -r '.tag_name' | cut -c2-); \
fi \
&& S6_PLATFORM=$(case "${TARGETARCH}/${TARGETVARIANT}" in \
"arm/v7") echo "armhf";; \
"arm64/") echo "aarch64";; \
*) echo "x86_64";; \
esac) \
&& echo "Using s6 release ${S6_RELEASE} platform ${S6_PLATFORM}" \
&& curl -sSL "https://github.com/just-containers/s6-overlay/releases/download/v${S6_RELEASE}/s6-overlay-noarch.tar.xz" -o "/tmp/s6-overlay-noarch.tar.xz" \
&& curl -sSL "https://github.com/just-containers/s6-overlay/releases/download/v${S6_RELEASE}/s6-overlay-${S6_PLATFORM}.tar.xz" -o "/tmp/s6-overlay-${S6_PLATFORM}.tar.xz" \
&& curl -sSL "https://github.com/just-containers/s6-overlay/releases/download/v${S6_RELEASE}/s6-overlay-noarch.tar.xz.sha256" -o "/tmp/s6-overlay-noarch.tar.xz.sha256" \
&& curl -sSL "https://github.com/just-containers/s6-overlay/releases/download/v${S6_RELEASE}/s6-overlay-${S6_PLATFORM}.tar.xz.sha256" -o "/tmp/s6-overlay-${S6_PLATFORM}.tar.xz.sha256" \
&& cd /tmp \
&& sha256sum -c s6-overlay-noarch.tar.xz.sha256 \
&& sha256sum -c s6-overlay-${S6_PLATFORM}.tar.xz.sha256 \
&& mkdir -p /s6/root \
&& tar -C /s6/root -Jxpf /tmp/s6-overlay-noarch.tar.xz \
&& tar -C /s6/root -Jxpf /tmp/s6-overlay-${S6_PLATFORM}.tar.xz
Loading

0 comments on commit 482972a

Please sign in to comment.