How-to
Publish a slowapp
Let CI check every push, then tag a release to publish your app's image for every hub platform.
A slowapp lives in its own Git repository, named slowapp-<id> by convention, and is published as a container image on GitHub’s registry. The template repository has everything below set up already.
Repository layout
slowapp.toml the manifest
Dockerfile FROM a pinned base image; the manifest goes to /app/slowapp.toml
<module>/ your code
fixtures/<name>/ test data for each [[example]]
tests/ unit tests, run inside the base image
.github/workflows/app.yml calls the shared workflow
The workflow
.github/workflows/app.yml is a few lines that call the shared workflow from slowapp-base:
name: app
on:
push:
branches: [main]
tags: ["v[0-9]+.[0-9]+.[0-9]+"]
pull_request:
workflow_dispatch:
jobs:
app:
uses: mike-anderson/slowapp-base/.github/workflows/app.yml@v1.0.0
permissions:
contents: write
packages: write
On every push and pull request it:
- takes the SDK out of the base image your Dockerfile pins, so your app is checked by the tools that match it;
- checks the manifest and runs your unit tests inside the base image;
- builds the image and renders every example twice, requiring identical pictures;
- uploads the previews, and shows the cards and their ids in the run summary;
- builds the image for 32-bit ARM, the Slowboard 1085’s platform.
Publish a release
Tag a version and push the tag:
git tag v0.1.0 && git push origin v0.1.0
The workflow pushes the image to ghcr.io for linux/arm/v7, linux/arm64 and linux/amd64, and writes the line to pin into the release notes:
image = "ghcr.io/<owner>/slowapp-<id>@sha256:…"
A hub runs an app by digest, never by tag, so a published version can’t change under anyone. To put the release on a hub, see Install a slowapp.
Keep the base image current
The base images release a patch every month with Debian’s security updates. Dependabot opens a pull request in your repository when a new one is out; merge it and tag a new release. Base images explains the versions.