Skip to Content
DocumentationFirst-Party Apps🟒 Static Container Builder

🟒 Static Container Builder

Ship a static site as an HTTPS container. A Dockerfile, nginx config, and entrypoint that bake any static site into a self-contained image that serves itself over HTTPS.

Install & availability

Available now. Install from the Companion Hub App Store. Verified on the test fleet: the published image pulls, starts, serves its web UI, and survives a container restart.

Hub App StoreSearch Static Container Builder β†’ Install
Container imageghcr.io/companionintelligence/ci-static-containter-builder:latest (public)
Ports80 (HTTP β†’ HTTPS redirect) and 443 (HTTPS)
Architecturelinux/amd64 and linux/arm64 (multi-arch)

Overview

The Static Container Builder is a small, practical build artifact: a Dockerfile + nginx config + entrypoint (with an alternate Spin/WASM variant) that packages a directory of static files into a container which serves them over HTTPS. You point it at your built static site and get back an image you can run anywhere β€” including as a Hub app.

It is not a CLI tool or an app framework. There is no scaffolding command, no manifest format, and no agent/memory integration β€” it is a container recipe for static hosting done well.

Current capabilities

What the Static Container Builder is today:

  • A Dockerfile + nginx config + entrypoint that bakes static files into an image
  • Serves on port 80 (redirects to HTTPS) and port 443 (HTTPS)
  • Uses a self-signed certificate by default, overridable via SSL_DOMAIN / SSL_CERT / SSL_KEY
  • Exposes a /health endpoint
  • A Spin / WASM image variant alongside the nginx one
  • Multi-arch images (amd64 + arm64)
  • The nginx image is hermetic / offline-safe at runtime β€” it needs no network to serve

Earlier versions of this page described a ci-builder CLI (init/build/deploy/package/inspect/status), a get.ci.computer/builder installer, a companion.yaml manifest, Hub-native *.ci.localhost auto-registration, memory hooks, MCP tool declarations, and Tools Cache Mount layer caching. None of those exist in this repository. The accurate usage is below.

Usage

You use the builder in one of two ways: build directly with a build arg, or base your own image on it.

Build with a build arg

docker build \ --build-arg STATIC_FILES_PATH=./dist \ -t my-static-site . docker run -p 8080:80 -p 8443:443 my-static-site

Base your image on it

FROM ghcr.io/companionintelligence/ci-static-containter-builder:latest COPY ./dist /usr/share/nginx/html

TLS configuration

By default the container generates and serves a self-signed certificate. To use your own certificate and hostname:

VariablePurpose
SSL_DOMAINHostname the certificate is issued for
SSL_CERTPath/contents of your certificate
SSL_KEYPath/contents of your private key

The container’s filesystem is not read-only/immutable: the entrypoint writes certificate material at startup. The nginx image is offline-safe at runtime, but it does mutate its own filesystem to set up TLS.

Health checks

A /health endpoint is available for liveness/readiness probes.

Use Cases

  • Package a built static site (docs, dashboard, landing page) into an HTTPS-serving container
  • Run a static admin/dashboard UI as a Hub app on its own port
  • Distribute a static site as a single OCI image with TLS already configured

Setup

Install from Hub

Search for Static Container Builder in the Hub app store and install to run the reference image.

Build your own site image

Either build with --build-arg STATIC_FILES_PATH=… pointing at your static output directory, or write a Dockerfile that does FROM ghcr.io/companionintelligence/ci-static-containter-builder:latest and COPY your files into the web root.

Configure TLS (optional)

Set SSL_DOMAIN, SSL_CERT, and SSL_KEY to use your own certificate instead of the self-signed default.

Troubleshooting

Browser warns about the certificate The default certificate is self-signed. Provide your own via SSL_DOMAIN / SSL_CERT / SSL_KEY, or trust the self-signed cert for testing.

docker build can’t find my files STATIC_FILES_PATH must point at a directory that exists in the build context. Make sure your static output (e.g. dist/) is built first and included.

Looking for ci-builder or companion.yaml Those don’t exist in this repo. Use the Dockerfile / build-arg / FROM approach above.

Last updated on