diff options
Diffstat (limited to '')
-rw-r--r-- | build/shim/Dockerfile | 17 | ||||
-rwxr-xr-x | build/shim/shim.php (renamed from shim/shim.php) | 4 |
2 files changed, 19 insertions, 2 deletions
diff --git a/build/shim/Dockerfile b/build/shim/Dockerfile new file mode 100644 index 0000000..986b931 --- /dev/null +++ b/build/shim/Dockerfile @@ -0,0 +1,17 @@ +FROM alpine:latest + +# install packages +RUN apk add --no-cache \ + php84 \ + php84-pdo \ + php84-pdo_sqlite \ + php84-pdo_pgsql \ + tini + +# copy scripts +COPY ./shim.php /usr/local/bin/shim.php +RUN chmod +x /usr/local/bin/shim.php + +# run +ENTRYPOINT ["/sbin/tini", "--"] +CMD ["/usr/local/bin/shim.php"] diff --git a/shim/shim.php b/build/shim/shim.php index eb84412..0c91513 100755 --- a/shim/shim.php +++ b/build/shim/shim.php @@ -1,9 +1,9 @@ -#!/usr/bin/env php +#!/usr/bin/env php84 <?php /* Copyright (c) 2024 Freya Murphy */ function wait_until_ready() { while (TRUE) { - if (file_exists("/status/ready")) { + if (file_exists("/var/run/crimson/db-ready")) { echo "database ready!\n"; break; } |