Skip to content

Add lean multi-stage Dockerfile and GitHub Actions workflow#128

Open
ricardoalcantara wants to merge 1 commit intotanabe:mainfrom
ricardoalcantara:main
Open

Add lean multi-stage Dockerfile and GitHub Actions workflow#128
ricardoalcantara wants to merge 1 commit intotanabe:mainfrom
ricardoalcantara:main

Conversation

@ricardoalcantara
Copy link

I'd like to contribute with Docker support to this project. My company has a policy that restricts employees from pasting documents on external websites, so being able to self-host the tool via a Docker image makes it much more accessible in those environments — no network dependency, no data leaving the machine.

What's included

  • Dockerfile — multi-stage build to keep the final image lean (~25–40 MB):

    1. Build (node:20-alpine) — installs dependencies and runs vite build
    2. Serve (nginx:alpine) — copies only the dist/ folder with a minimal SPA-friendly nginx config
  • .github/workflows/docker.yml — builds and pushes the image to GHCR on every push to main

Usage

docker build -t markdown-live-preview .
docker run -p 8080:80 markdown-live-preview

Feel free to close this if it doesn't fit the project's goals.

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.

1 participant