Skip to content

feat: add Dockerfile for NestJS API (#115)#155

Merged
legend-esc merged 2 commits into
legend-esc:mainfrom
kenedybok3:feat/dockerfile-nestjs-api
May 27, 2026
Merged

feat: add Dockerfile for NestJS API (#115)#155
legend-esc merged 2 commits into
legend-esc:mainfrom
kenedybok3:feat/dockerfile-nestjs-api

Conversation

@kenedybok3
Copy link
Copy Markdown
Contributor

Summary

Closes #115

Adds containerization support for the NestJS API.

Changes

  • api/Dockerfile: Multi-stage build

    • builder stage: installs all deps and compiles TypeScript via npm run build
    • production stage: installs only production deps (npm ci --omit=dev), copies compiled dist/ from builder
    • Base image: node:18-alpine
    • Exposes port 3000
    • Entry point: node dist/main
  • api/.dockerignore: Excludes node_modules, dist, coverage, .env files, and logs from the build context

  • .github/workflows/ci.yml: Adds a docker job that builds the image on every push/PR to validate the Dockerfile

Checklist

  • Multi-stage build
  • node:18-alpine base image
  • Production dependencies only in final stage
  • .dockerignore added
  • CI docker-build job added

- Multi-stage build: builder stage compiles TypeScript, production stage
  includes only prod dependencies (npm ci --omit=dev)
- Uses node:18-alpine base image
- Exposes port 3000
- Add api/.dockerignore to exclude node_modules, dist, coverage, .env files
- Add docker-build job to CI workflow
@drips-wave
Copy link
Copy Markdown

drips-wave Bot commented May 27, 2026

@kenedybok3 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@legend-esc legend-esc merged commit 3247636 into legend-esc:main May 27, 2026
1 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Dockerfile for NestJS API

2 participants