Appearance
Dockerfiles
If the service's root directory contains a Dockerfile, dockerfile or Containerfile, Fjordrun builds it as is. A repository Dockerfile always takes precedence over framework detection and Nixpacks.
Custom path
Set Settings → Build → Dockerfile path to use another file, for example docker/Dockerfile.prod. The path is relative to the root directory and may not contain ... If the file does not exist, the build fails with:
text
Dockerfile path 'docker/Dockerfile.prod' (build.dockerfile_path) does not exist in the build contextSetting the builder to Dockerfile makes a missing Dockerfile an error instead of falling back to detection.
Build context
For a repository Dockerfile, the build context is the root directory (like docker build <root dir>). Files outside it are not available to COPY. If you need them, set the root directory to the repository root and point the Dockerfile path at the sub-folder's Dockerfile.
Your .dockerignore is respected. Fjordrun adds .git, **/node_modules, **/.DS_Store and **/._* to it.
Build arguments
The service's variables are passed as build arguments. Declare the ones you need with ARG in the stage that uses them:
dockerfile
FROM node:22-alpine AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
ARG VITE_API_URL
RUN npm run buildUndeclared variables are not visible to the build. See Build variables.
Runtime requirements
- Listen on
0.0.0.0and the port in$PORT(8080 by default), or set the service's Port to the port your image listens on. - Run as a non-root user if you can. Containers run with Kubernetes' baseline pod security policy.
- Write persistent data only under a volume mount path.
- The image's
CMDis used unless you set a start command.
See the Docker guide for a complete example.