Skip to content

Docker ​

There are two ways to run your own container on Fjordrun.

A Dockerfile in your repository ​

Push a repository with a Dockerfile and Fjordrun builds it on every push. A repository Dockerfile always takes precedence over framework detection. See Dockerfiles for the build context, custom paths and build arguments.

Example: a Vite app served by nginx as non-root on port 8080:

dockerfile
FROM node:22-alpine AS build
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci
COPY . .
ARG VITE_API_URL
RUN npm run build

FROM nginxinc/nginx-unprivileged:1.27-alpine
COPY --from=build /app/dist /usr/share/nginx/html
EXPOSE 8080

nginxinc/nginx-unprivileged listens on 8080, which matches the default port of web services.

A prebuilt image ​

Create a service with Docker image as the source and enter the image reference, for example ghcr.io/owner/app:1.4.2. Fjordrun deploys it without building. Use this when you build images in your own CI; see CI/CD with GitHub Actions.

The image must be available for linux/arm64: during the beta, Fjordrun's servers are arm64 machines. Most official images (nginx, postgres, redis, node, python...) are multi-platform. For your own images, build with --platform linux/amd64,linux/arm64.

Container checklist ​

  • Listen on 0.0.0.0:$PORT, or set Port to the port the image uses.
  • Log to stdout and stderr; Fjordrun collects them as runtime logs.
  • Keep state on a volume; the rest of the filesystem is reset on every deployment.
  • Handle SIGTERM to shut down gracefully during redeploys.
  • Prefer a non-root user.

Fjordrun is hosted in the EU (Hetzner, Nuremberg, Germany). Private beta.