Password Manager experiment built on ATProto Spaces
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637# Stage 1: Build the web application and core dependenciesFROM --platform=$BUILDPLATFORM node:22-alpine AS builder
WORKDIR /app
# Copy package manifests for optimal layer cachingCOPY package*.json ./COPY packages/core/package*.json ./packages/core/COPY packages/cli/package*.json ./packages/cli/COPY packages/web/package*.json ./packages/web/
# Install dependencies using clean installRUN npm ci
# Copy full source repositoryCOPY . .
# Build core library and web applicationRUN npm run build --workspace=@2password/core && npm run build --workspace=@2password/web
# Stage 2: Production Node.js runtime (no Nginx)FROM node:22-alpine AS runner
WORKDIR /app
ENV NODE_ENV=productionENV PORT=3000ENV HOST=0.0.0.0
# Copy built distribution and server scriptCOPY --from=builder /app/packages/web/dist ./packages/web/distCOPY packages/web/server.mjs ./packages/web/server.mjs
EXPOSE 3000
CMD ["node", "packages/web/server.mjs"]