Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(docker/rootless): entrypoint if executable bit is not set
Elian Doran02fc5214a3bf
diff --git a/apps/server/Dockerfile.alpine.rootless b/apps/server/Dockerfile.alpine.rootlessindex 5e6cba525e..e8bd0461f6 100644--- a/apps/server/Dockerfile.alpine.rootless+++ b/apps/server/Dockerfile.alpine.rootless@@ -26,7 +26,6 @@ WORKDIR /home/${USER}/appCOPY ./dist /home/${USER}/app# Also copy the rootless entrypoint scriptCOPY rootless-entrypoint.sh /home/${USER}/app/-RUN chmod +x /home/${USER}/app/rootless-entrypoint.shRUN rm -rf /home/${USER}/app/node_modules/better-sqlite3COPY --from=builder /usr/src/app/node_modules/better-sqlite3 /home/${USER}/app/node_modules/better-sqlite3RUN chown -R ${USER}:${USER} /home/${USER}@@ -45,6 +44,6 @@ ENV TRILIUM_DATA_DIR=/home/${USER}/trilium-dataENTRYPOINT ["/usr/bin/dumb-init", "--"]# Use the entrypoint script-CMD /home/${USER}/app/rootless-entrypoint.sh+CMD [ "bash", "./rootless-entrypoint.sh" ]HEALTHCHECK --start-period=10s CMD node /home/${USER}/app/docker_healthcheck.jsdiff --git a/apps/server/Dockerfile.rootless b/apps/server/Dockerfile.rootlessindex df94ddb90d..ca77f85baf 100644--- a/apps/server/Dockerfile.rootless+++ b/apps/server/Dockerfile.rootless@@ -28,7 +28,6 @@ WORKDIR /home/${USER}/appCOPY ./dist /home/${USER}/app# Also copy the rootless entrypoint scriptCOPY rootless-entrypoint.sh /home/${USER}/app/-RUN chmod +x /home/${USER}/app/rootless-entrypoint.shRUN rm -rf /home/${USER}/app/node_modules/better-sqlite3COPY --from=builder /usr/src/app/node_modules/better-sqlite3 /home/${USER}/app/node_modules/better-sqlite3RUN chown -R ${USER}:${USER} /home/${USER}@@ -44,6 +43,6 @@ ENV TRILIUM_GID=${GID}ENV TRILIUM_DATA_DIR=/home/${USER}/trilium-data# Use the entrypoint script-CMD /home/${USER}/app/rootless-entrypoint.sh+CMD [ "bash", "./rootless-entrypoint.sh" ]HEALTHCHECK --start-period=10s CMD node /home/${USER}/app/docker_healthcheck.jsdiff --git a/apps/server/rootless-entrypoint.sh b/apps/server/rootless-entrypoint.shindex 0d580285f8..4056df2a29 100755--- a/apps/server/rootless-entrypoint.sh+++ b/apps/server/rootless-entrypoint.sh@@ -1,4 +1,4 @@-#!/bin/sh+#!/bin/bash# Rootless entrypoint script for Trilium Notes# Works with both Debian and Alpine-based images