Skip to content

Instantly share code, notes, and snippets.

@virae
Created January 9, 2023 10:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save virae/29a62c403135b2e065a2bc71973271cf to your computer and use it in GitHub Desktop.
Save virae/29a62c403135b2e065a2bc71973271cf to your computer and use it in GitHub Desktop.
Supercronic docker
...
ENV SUPERCRONIC_URL=https://github.com/aptible/supercronic/releases/download/v0.2.1/supercronic-linux-amd64 \
SUPERCRONIC=supercronic-linux-amd64 \
SUPERCRONIC_SHA1SUM=d7f4c0886eb85249ad05ed592902fa6865bb9d70
RUN curl -fsSLO "$SUPERCRONIC_URL" \
&& 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
...
# Generate crontab
RUN bundle exec whenever > /app/crontab
RUN supercronic /app/crontab
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment