Finalize annoNet production image

This commit is contained in:
Admin 2026-09-21 22:02:25 +00:00
parent 9570a7a581
commit 6232b25ad0

View File

@ -4,7 +4,6 @@ WORKDIR /src
COPY annonet-arrowstack-ready.zip /tmp/annonet.zip COPY annonet-arrowstack-ready.zip /tmp/annonet.zip
RUN unzip -q /tmp/annonet.zip -d /src RUN unzip -q /tmp/annonet.zip -d /src
COPY mcpAuthMiddleware.js /src/src/auth/mcpAuthMiddleware.js COPY mcpAuthMiddleware.js /src/src/auth/mcpAuthMiddleware.js
COPY scopeProbe.js /src/scopeProbe.js
# Arrowstack's database-per-tenant runtime role intentionally cannot install # Arrowstack's database-per-tenant runtime role intentionally cannot install
# extensions. PostgreSQL 13+ provides gen_random_uuid() in core, and annoNet # extensions. PostgreSQL 13+ provides gen_random_uuid() in core, and annoNet
# does not use any other pgcrypto functions. # does not use any other pgcrypto functions.
@ -33,7 +32,6 @@ COPY --from=source /src/src ./src
COPY --from=source /src/sql ./sql COPY --from=source /src/sql ./sql
COPY --from=source /src/scripts ./scripts COPY --from=source /src/scripts ./scripts
COPY --from=source /src/frontend ./frontend COPY --from=source /src/frontend ./frontend
COPY --from=source /src/scopeProbe.js ./scopeProbe.js
COPY --from=frontend-build /build/frontend-astro/dist ./public COPY --from=frontend-build /build/frontend-astro/dist ./public
RUN npm run check \ RUN npm run check \
@ -46,4 +44,4 @@ EXPOSE 8787
HEALTHCHECK --interval=10s --timeout=5s --start-period=20s --retries=6 \ HEALTHCHECK --interval=10s --timeout=5s --start-period=20s --retries=6 \
CMD node -e "fetch('http://127.0.0.1:8787/api/health/ready').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))" CMD node -e "fetch('http://127.0.0.1:8787/api/health/ready').then(r=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))"
CMD ["sh", "-c", "npm run migrate && node scopeProbe.js && node src/server.js"] CMD ["npm", "start"]