oxynote/server/auth-realtime/Dockerfile.dev
dependabot[bot] 1c1e9eafbf deps(docker): bump the safe group across 3 directories with 2 updates
Bumps the safe group with 2 updates in the /docker/prod directory: node and alpine.
Bumps the safe group with 1 update in the /server/auth-realtime directory: node.
Bumps the safe group with 1 update in the /web directory: node.


Updates `node` from 24.19.0-bookworm-slim to 24.20.0-bookworm-slim

Updates `alpine` from 3.23 to 3.24

Updates `node` from 24.19.0-bookworm-slim to 24.20.0-bookworm-slim

Updates `node` from 24.19.0-bookworm-slim to 24.20.0-bookworm-slim

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

Updates `node` from 24.19.0-alpine to 24.20.0-alpine

---
updated-dependencies:
- dependency-name: alpine
  dependency-version: '3.24'
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: safe
- dependency-name: node
  dependency-version: 24.20.0-alpine
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: safe
- dependency-name: node
  dependency-version: 24.20.0-alpine
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: safe
- dependency-name: node
  dependency-version: 24.20.0-bookworm-slim
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: safe
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-31 13:53:29 +02:00

36 lines
1.0 KiB
Docker

# inspired by: https://hono.dev/docs/getting-started/nodejs#dockerfile
FROM node:24.20.0-alpine AS base
FROM base AS builder
RUN apk add --no-cache gcompat
RUN npm install -g pnpm
WORKDIR /server
# pnpm-workspace.yaml carries the allowBuilds settings — without it the
# install refuses to run the esbuild install script.
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml tsconfig.json tsconfig.build.json ./
COPY src ./src
# check-types gates (esbuild does not look at types); build:bundle emits
# the single-file runtime artifact the production image ships too
RUN pnpm install --frozen-lockfile && \
pnpm run check-types && \
pnpm run build:bundle
FROM base AS runner
WORKDIR /server
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 hono
# the bundle folds sentry in (no --import preload) and carries every
# dependency, so no node_modules are shipped.
COPY --from=builder --chown=hono:nodejs /server/dist/bundle.mjs /server/bundle.mjs
ENV NODE_ENV=production
USER hono
EXPOSE 8081
CMD ["node", "/server/bundle.mjs"]