Self-host the email template builder.

Card is a client-side Vue app: no backend, no database, no accounts. This guide covers both ways to run it on your own infrastructure — a plain static build behind nginx or Caddy, and a Docker container — plus what AGPL-3.0 means for company use.

Short answer

Build once, serve static files. Five minutes with a web server you already run.

What you need

  • Static build: a current LTS release of Node.js and pnpm — only at build time.
  • Docker: just Docker. The image builds Card and serves it with nginx.

Nothing else. There is no database to provision and no environment variables to configure — the app runs entirely in the visitor's browser.

Option 1 — static build

Clone the repository, install dependencies and build. The result is a dist/ folder of plain static assets:

shell
git clone https://github.com/mysigmail/card.git
cd card
pnpm install
pnpm build
# → static files in dist/

Point any web server at that folder. With nginx, a fallback to index.html keeps client-side routing working:

nginx.conf
server {
  listen 80;
  server_name builder.example.com;
  root /var/www/card/dist;
  index index.html;

  location / {
    try_files $uri $uri/ /index.html;
  }
}
Caddyfile
builder.example.com {
  root * /var/www/card/dist
  file_server
  try_files {path} /index.html
}

The same build deploys to any static host — Cloudflare Pages, Netlify or GitHub Pages. Set the build command to pnpm build and the output directory to dist. For a GitHub Pages project site such as https://user.github.io/card/, build with the repository path so asset URLs resolve correctly:

shell
VITE_APP_BASE_PATH=/card/ pnpm build

Replace /card/ with your repository name. A custom domain served from its root can keep the default / base path.

Option 2 — Docker

There is no official image yet, so the container is built from source. A two-stage Dockerfile keeps the final image small: Node builds the static files, nginx serves them.

Dockerfile
FROM node:22-alpine AS build
WORKDIR /app
RUN npm install -g pnpm
COPY package.json pnpm-lock.yaml ./
RUN pnpm install --frozen-lockfile
COPY . .
RUN pnpm build

FROM nginx:alpine
COPY --from=build /app/dist /usr/share/nginx/html
EXPOSE 80
shell
docker build -t mysigmail-card .
docker run -d --name card -p 8080:80 mysigmail-card
# → http://localhost:8080

Or with Docker Compose, if Card joins an existing stack:

compose.yaml
services:
  card:
    build: .
    ports:
      - "8080:80"
    restart: unless-stopped

Updating

Updates are a pull and a rebuild — there is no migration step, because there is no server-side state. Versions and changelogs are published on the GitHub releases page.

shell
cd card
git pull
pnpm install && pnpm build
# Docker: docker compose up -d --build

What you're actually running

A self-hosted Card deployment is deliberately boring to operate. Everything a template touches stays in the browser of the person editing it:

BackendNone — static files only
DatabaseNone
Template storageBrowser localStorage
HTML / JSON exportGenerated in the browser
TelemetryOff by default
LicenceAGPL-3.0

Licensing for self-hosters

Card is distributed under AGPL-3.0. In practice, for a self-hosted deployment:

  • Running Card for yourself or inside your company is free, including commercial use.
  • If you modify Card and serve it to users over a network, those users must be able to get the source of your modified version.
  • Embedding the editor in a closed-source product requires a commercial licence.

Frequently asked questions

Is there an official Docker image?

Not yet. The recommended way to run Card in Docker is the multi-stage Dockerfile from this guide: a Node stage builds the static files, an nginx stage serves them. Watch the GitHub releases page for an official image.

Does Card need a database or a backend?

No. Card is a client-side Vue application. A deployment is a folder of static files behind any web server. Templates auto-save to the browser's localStorage, and HTML/JSON exports are generated in the browser.

Can my company self-host Card for free?

Yes. Card is licensed under AGPL-3.0, which permits free commercial use, including internal company deployments. If you modify Card and make it available to users over a network, the licence requires you to offer them the source of your modified version. To embed the editor in a closed-source product instead, a commercial licence is available.

How do I update a self-hosted instance?

Pull the latest code and rebuild: git pull, pnpm install, pnpm build — or rebuild the Docker image. Releases are published on GitHub with changelogs.

What are the server requirements?

Any server that can serve static files: nginx, Caddy, Apache, or a static host like Cloudflare Pages or Netlify. The build output is a few megabytes of assets with no server-side runtime. Node.js is only needed at build time.

Can I add my own blocks or templates?

Yes. Card is a Vue 3 + TypeScript codebase, and the block catalog can be extended in code. Keep in mind that AGPL-3.0 applies to modified versions you serve to users over a network.