Some checks are pending
Bidi Control Character Guard / bidi-control-guard (push) Waiting to run
Circular Dependency Check / Check for new circular dependencies (push) Waiting to run
Citus Migration Smoke / Combined migrations on single-node Citus (push) Waiting to run
E2E Fresh Install Tests / fresh-install-e2e (push) Waiting to run
ext-v2 guardrails / Run ext-v2 guard and ESLint (push) Waiting to run
Integration Tests / Check for relevant changes (push) Waiting to run
Integration Tests / ${{ (github.event_name == 'schedule' || github.event.inputs.suite == 'full') && 'Full integration suite' || 'Tier-1 integration subset' }} (push) Blocked by required conditions
Mobile checks / Mobile lint + typecheck (push) Waiting to run
Mobile checks / Mobile unit tests (push) Waiting to run
Mobile checks / Mobile dependency audit (report) (push) Waiting to run
Mobile checks / Mobile reproducibility checks (push) Waiting to run
Secrets guard (env backups) / Ensure no tracked env backup files (push) Waiting to run
Temporal Readiness / fast-readiness (push) Waiting to run
Temporal Readiness / docker-parity (push) Waiting to run
TypeScript Type Check / Nx affected typecheck (push) Waiting to run
Unit Tests / Skipped-test budget (push) Waiting to run
Unit Tests / Nx affected unit tests (push) Waiting to run
Unit Tests / Server unit coverage (informational) (push) Waiting to run
Validate Tenant Management Schema / Check for relevant changes (push) Waiting to run
Validate Tenant Management Schema / Validate Tenant Management Schema (push) Blocked by required conditions
EE Workflows Build Guard / ee-workflows-build-guard (push) Waiting to run
Excluded: .git, node_modules, secrets/, compose.env, assemblyscript tgz Source: /opt/alga-psa on psa.joliet.tech
91 lines
2.6 KiB
Docker
91 lines
2.6 KiB
Docker
FROM node:20.19-alpine AS builder
|
|
|
|
RUN apk add --no-cache \
|
|
postgresql-client \
|
|
curl \
|
|
bash
|
|
|
|
WORKDIR /app
|
|
|
|
RUN npm install -g typescript @types/node tsc-alias
|
|
|
|
COPY tsconfig.base.json ./
|
|
COPY tsconfig.json ./
|
|
COPY types/ ./types/
|
|
COPY package.json package-lock.json ./
|
|
|
|
COPY shared/package.json ./shared/
|
|
COPY services/email-service/package.json ./services/email-service/
|
|
COPY server/package.json ./server/
|
|
COPY packages/core/package.json ./packages/core/
|
|
COPY packages/db/package.json ./packages/db/
|
|
COPY packages/ee/package.json ./packages/ee/
|
|
COPY packages/event-bus/package.json ./packages/event-bus/
|
|
COPY packages/event-schemas/package.json ./packages/event-schemas/
|
|
COPY packages/storage/package.json ./packages/storage/
|
|
COPY packages/types/package.json ./packages/types/
|
|
|
|
RUN npm config set legacy-peer-deps true && npm install --include-workspace-root \
|
|
--workspace=@alga-psa/shared \
|
|
--workspace=email-service \
|
|
--workspace=server \
|
|
--workspace=@alga-psa/core \
|
|
--workspace=@alga-psa/db \
|
|
--workspace=@alga-psa/ee-stubs \
|
|
--workspace=@alga-psa/event-bus \
|
|
--workspace=@alga-psa/event-schemas \
|
|
--workspace=@alga-psa/storage \
|
|
--workspace=@alga-psa/types
|
|
|
|
COPY shared/ ./shared/
|
|
COPY server/ ./server/
|
|
COPY packages/ ./packages/
|
|
|
|
WORKDIR /app/packages/core
|
|
RUN npm run build && tsc-alias -p tsconfig.json -f --resolve-full-paths
|
|
|
|
WORKDIR /app/packages/db
|
|
RUN npm run build && tsc-alias -p tsconfig.json -f --resolve-full-paths
|
|
|
|
WORKDIR /app/packages/event-schemas
|
|
RUN npm run build
|
|
|
|
WORKDIR /app/packages/event-bus
|
|
RUN npm run build
|
|
|
|
WORKDIR /app/shared
|
|
RUN npm run build
|
|
|
|
WORKDIR /app/packages/storage
|
|
RUN npm run build
|
|
|
|
WORKDIR /app/services/email-service
|
|
COPY services/email-service/ ./
|
|
RUN npm run build
|
|
|
|
COPY services/email-service/entrypoint.sh /app/entrypoint.sh
|
|
RUN chmod +x /app/entrypoint.sh
|
|
|
|
# Trim build-time-only bulk in the builder so the runtime COPY captures the
|
|
# already-trimmed tree (deleting after the COPY would not reclaim space).
|
|
# server/ is type-imports-only at build; the email service never loads it.
|
|
RUN rm -rf /app/server /app/node_modules/server \
|
|
&& npm cache clean --force 2>/dev/null || true
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# Runtime stage: clean image with only the runtime tree (drops intermediate
|
|
# build layers + server/ source).
|
|
# ---------------------------------------------------------------------------
|
|
FROM node:20.19-alpine AS runtime
|
|
|
|
RUN apk add --no-cache \
|
|
postgresql-client \
|
|
curl \
|
|
bash
|
|
|
|
WORKDIR /app
|
|
COPY --from=builder /app /app
|
|
|
|
ENV NODE_ENV=production
|
|
ENTRYPOINT ["/app/entrypoint.sh"]
|