From d6a3ea49a03bb55c955f533125e1f09b88147cd4 Mon Sep 17 00:00:00 2001 From: Raju Udava <86527202+dstala@users.noreply.github.com> Date: Thu, 9 May 2024 22:03:23 +0530 Subject: [PATCH] chore: skip build tar & untar step from dockerfile (#8440) Co-authored-by: Pranav C --- packages/nocodb/Dockerfile | 3 +-- packages/nocodb/Dockerfile.local | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/packages/nocodb/Dockerfile b/packages/nocodb/Dockerfile index 4ef1519301..228352072c 100644 --- a/packages/nocodb/Dockerfile +++ b/packages/nocodb/Dockerfile @@ -44,7 +44,6 @@ RUN echo "node-linker=hoisted" > .npmrc RUN pnpm install --prod --shamefully-hoist \ && pnpm dlx modclean --patterns="default:*" --ignore="nc-lib-gui/**,dayjs/**,express-status-monitor/**,@azure/msal-node/dist/**" --run \ && rm -rf ./node_modules/sqlite3/deps \ - && tar -czf ../appEntry/app.tar.gz ./* \ && chmod +x /usr/src/appEntry/start.sh ########## @@ -60,12 +59,12 @@ ENV NC_TOOL_DIR=/usr/app/data/ RUN apk --update --no-cache add \ nodejs \ - tar \ dumb-init # Copy litestream binary build COPY --from=lt-builder /usr/src/lt /usr/src/appEntry/litestream # Copy packaged production code & main entry file +COPY --from=builder /usr/src/app/ /usr/src/app/ COPY --from=builder /usr/src/appEntry/ /usr/src/appEntry/ EXPOSE 8080 diff --git a/packages/nocodb/Dockerfile.local b/packages/nocodb/Dockerfile.local index ee6a0ffd1c..5a3687386b 100644 --- a/packages/nocodb/Dockerfile.local +++ b/packages/nocodb/Dockerfile.local @@ -28,7 +28,6 @@ RUN pnpm uninstall nocodb-sdk RUN pnpm install --prod --shamefully-hoist --reporter=silent \ && pnpm dlx modclean --patterns="default:*" --ignore="nc-lib-gui/**,dayjs/**,express-status-monitor/**,@azure/msal-node/dist/**" --run \ && rm -rf ./node_modules/sqlite3/deps \ - && tar -czf ../appEntry/app.tar.gz ./* \ && chmod +x /usr/src/appEntry/start.sh ########## @@ -44,12 +43,12 @@ ENV NC_TOOL_DIR=/usr/app/data/ RUN apk --update --no-cache add \ nodejs \ - tar \ dumb-init \ curl \ jq # Copy packaged production code & main entry file +COPY --from=builder /usr/src/app/ /usr/src/app/ COPY --from=builder /usr/src/appEntry/ /usr/src/appEntry/ EXPOSE 8080