Skip to content

Commit

Permalink
fix: Install supercronic from Alpine repo (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
MattKobayashi authored Oct 8, 2024
1 parent e6db8fd commit ba36189
Showing 1 changed file with 2 additions and 19 deletions.
21 changes: 2 additions & 19 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,10 @@ FROM python:3.13.0-alpine3.20

WORKDIR /opt/fuelhook

ARG TARGETPLATFORM
ENV SUPERCRONIC_SHA1SUM_amd64=cd48d45c4b10f3f0bfdd3a57d054cd05ac96812b \
SUPERCRONIC_SHA1SUM_arm=75e065bf0909f920b06d5bd797c0e6b31e68b112 \
SUPERCRONIC_SHA1SUM_arm64=512f6736450c56555e01b363144c3c9d23abed4c \
SUPERCRONIC_SHA1SUM_i386=3436985298ce241d7d9477eb9eab164b582717a8 \
SUPERCRONIC_VERSION=v0.2.29

RUN if [ "$TARGETPLATFORM" = "linux/amd64" ]; then ARCH=amd64; elif [ "$TARGETPLATFORM" = "linux/arm/v7" ]; then ARCH=arm; elif [ "$TARGETPLATFORM" = "linux/arm64" ]; then ARCH=arm64; elif [ "$TARGETPLATFORM" = "linux/i386" ]; then ARCH=i386; else exit 1; fi \
&& export SUPERCRONIC="supercronic-linux-${ARCH}" \
&& export SUPERCRONIC_URL="https://github.com/aptible/supercronic/releases/download/${SUPERCRONIC_VERSION}/${SUPERCRONIC}" \
&& wget "$SUPERCRONIC_URL" \
&& eval SUPERCRONIC_SHA1SUM='$SUPERCRONIC_SHA1SUM_'$ARCH \
&& echo "${SUPERCRONIC_SHA1SUM} ${SUPERCRONIC}" | sha1sum -c - \
&& chmod +x "${SUPERCRONIC}" \
&& mv "$SUPERCRONIC" "/usr/local/bin/${SUPERCRONIC}" \
&& ln -s "/usr/local/bin/${SUPERCRONIC}" /usr/local/bin/supercronic \
&& addgroup -S fuelhook && adduser -S fuelhook -G fuelhook \
RUN addgroup -S fuelhook && adduser -S fuelhook -G fuelhook \
&& mkdir -p data \
&& chown fuelhook:fuelhook data \
&& apk --no-cache upgrade \
&& apk add --no-cache tzdata
&& apk --no-cache add supercronic tzdata

USER fuelhook

Expand Down

0 comments on commit ba36189

Please sign in to comment.