Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

Commit

Permalink
fix(startup): update docker entrypoint so we can mount EFS volumes fo…
Browse files Browse the repository at this point in the history
…r warp-cache on startup
  • Loading branch information
dtfiedler committed Jan 16, 2024
1 parent 2b5e1f0 commit 35ce108
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
7 changes: 5 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,10 @@ USER node
# Copy build files
COPY --from=builder --chown=node /usr/src/app .

# Setup port
EXPOSE 3000

# Add labels
LABEL org.opencontainers.image.title="ar.io - ArNS Service"

EXPOSE 3000
CMD ["./dist/app.js"]
ENTRYPOINT [ "/bin/sh", "entrypoint.sh" ]
9 changes: 9 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh
# Check and set permissions if necessary
if [ -d "/usr/src/app/cache" ]; then
chown -R node:node /usr/src/app/cache
chmod -R 755 /usr/src/app/cache
fi

# run the app
exec /nodejs/bin/node /usr/src/app/dist/app.js
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
},
"dependencies": {
"@ardrive/ardrive-promise-cache": "^1.1.4",
"@commitlint/config-conventional": "^17.7.0",
"@koa/cors": "^4.0.0",
"@koa/router": "^12.0.0",
"arweave": "^1.13.7",
Expand All @@ -57,6 +56,7 @@
"@types/node": "^18.15.11",
"@typescript-eslint/eslint-plugin": "^5.59.11",
"@typescript-eslint/parser": "^5.59.11",
"@commitlint/config-conventional": "^17.7.0",
"axios": "^1.4.0",
"chai": "^4.3.7",
"commitlint": "^17.7.1",
Expand Down

0 comments on commit 35ce108

Please sign in to comment.