-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
dfee6bc
commit 75bf9df
Showing
2 changed files
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
FROM alpine:3.18.4@sha256:eece025e432126ce23f223450a0326fbebde39cdf496a85d8c016293fc851978 | ||
|
||
RUN apk add --update --no-cache \ | ||
ca-certificates \ | ||
curl \ | ||
jq \ | ||
supercronic \ | ||
tzdata \ | ||
&& rm -rf /var/cache/apk/* /.cache | ||
|
||
COPY --chmod=500 entry.sh /entry.sh | ||
COPY --chmod=500 unlock.sh /usr/local/bin/unlock | ||
|
||
CMD ["/entry.sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/sh | ||
|
||
if [ -n "$CRONTAB" ]; then | ||
echo "$CRONTAB" > /crontab.txt | ||
else | ||
echo "Error: Missing 'CRONTAB' environment variable" | ||
exit 1 | ||
fi | ||
|
||
# Test crontab | ||
echo "Testing crontab.txt" | ||
supercronic -test -debug /crontab.txt || exit 1 | ||
|
||
# Start supercronic | ||
supercronic -passthrough-logs /crontab.txt |