Skip to content

Commit 1a9eeed

Browse files
committed
polish and rename balfolk ics
1 parent a2f57c8 commit 1a9eeed

File tree

5 files changed

+6
-10
lines changed

5 files changed

+6
-10
lines changed
Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,14 @@ RUN pip install --no-cache-dir requests beautifulsoup4 icalendar pytz
99
WORKDIR /app
1010

1111
# Copy code
12-
COPY --chown=nobody:nogroup ./app /app
12+
COPY --chown=nobody:nogroup . /
1313

1414
# Create output dir for serving
1515
RUN touch /app/balfolk.ics
1616

1717
# Setup cron
18-
RUN apk add --no-cache bash curl busybox-suid && \
19-
echo "#!/bin/sh\ncrond -f -L /dev/stdout" > /start.sh && \
20-
chmod +x /start.sh
18+
RUN apk add --no-cache busybox-suid && crontab /app/crontab.txt
2119

2220
# Install cron job
2321
RUN crontab /app/crontab.txt
2422

25-
# Start cron and HTTP server
26-
CMD sh -c "python3 /app/balfolk_ical.py && crond -f -L /dev/stdout & python3 -m http.server 8000 --directory /app"
27-
28-
29-
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
target "docker-metadata-action" {}
22

33
variable "APP" {
4-
default = "bfics"
4+
default = "balfolk-ics"
55
}
66

77
variable "VERSION" {

apps/balfolk-ics/start.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
3+
python3 /app/balfolk_ical.py && crond -f -L /dev/stdout & python3 -m http.server 8000 --directory /app

0 commit comments

Comments
 (0)