Skip to content

Commit 2b5b662

Browse files
committed
Added bind mount for user script
1 parent ce403a0 commit 2b5b662

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

Dockerfile

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,10 @@ RUN chmod +x /healthcheck.sh /docker-entrypoint.sh
6464
RUN mkdir -p /usr/local/bin
6565
RUN mkdir -p /usr/local/scripts
6666

67-
# Copy scripts
67+
# Copy wrapper script
6868
COPY scripts/check_and_run.sh /usr/local/bin/
6969
RUN chmod +x /usr/local/bin/check_and_run.sh
7070

71-
# Copy user check script if it exists (will be skipped if file doesn't exist)
72-
COPY scripts/check-script.sh /usr/local/scripts/ 2>/dev/null || true
73-
RUN chmod +x /usr/local/scripts/check-script.sh 2>/dev/null || true
74-
7571
# Add healthcheck
7672
HEALTHCHECK --interval=30s --timeout=5s --start-period=5s --retries=3 CMD ["sh", "-c", "/healthcheck.sh"]
7773

docker-compose.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ services:
99
- NET_BROADCAST
1010
- NET_RAW
1111
network_mode: host
12+
volumes:
13+
- ./scripts:/usr/local/scripts:ro
1214
env_file:
1315
- .env
1416
healthcheck:

0 commit comments

Comments
 (0)