Skip to content

Adding docker #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Adding docker #4

wants to merge 2 commits into from

Conversation

njmote
Copy link

@njmote njmote commented Jan 20, 2025

Thank you so much for creating this app, I had a lot of fun talking with it this morning. I've included some instructions on how to get it running in Docker.

@PylotLight
Copy link

You could use bun instead potentially, it worked for me.:

FROM oven/bun:alpine

WORKDIR /usr/src/app

COPY package*.json ./
RUN bun install

COPY . .

EXPOSE 3000

CMD ["bun","--bun", "run", "dev"]

@msirendi msirendi mentioned this pull request Feb 21, 2025
Copy link

@sidrtx sidrtx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor suggestions:

  • If this image will be used for production, consider using npm ci instead of npm install for more reliable builds.
  • And you might want to add a .dockerignore file to reduce image size by excluding files like node_modules, .git, etc.

Overall, this Dockerfile is clean, minimal, and follows best practices for a Node.js app in a development environment. Nice

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.

3 participants