mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
Merge pull request #2864 from dousha/master
Fix docker data permissions
This commit is contained in:
commit
6f75f944a3
@ -21,10 +21,15 @@ RUN set -x \
|
|||||||
&& npm install --production \
|
&& npm install --production \
|
||||||
&& apk del .build-dependencies
|
&& apk del .build-dependencies
|
||||||
|
|
||||||
|
# Some setup tools need to be kept
|
||||||
|
RUN apk add --no-cache su-exec
|
||||||
|
|
||||||
# Bundle app source
|
# Bundle app source
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
USER node
|
# Add application user and setup proper volume permissions
|
||||||
|
RUN adduser -s /bin/false node; exit 0
|
||||||
|
|
||||||
|
# Start the application
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
CMD [ "node", "./src/www" ]
|
CMD [ "./start-docker.sh" ]
|
||||||
|
4
start-docker.sh
Executable file
4
start-docker.sh
Executable file
@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
chown -R node:node /home/node
|
||||||
|
su-exec node node ./src/www
|
Loading…
x
Reference in New Issue
Block a user