VACANCY

One cheap server.
Every app.
Zero downtime.

motel is one Debian package: your reverse proxy, deploy pipeline, rate limiter, page cache and hourly backups, with config and secrets kept in git. Push to main, and the new version takes traffic once it has passed its health check. No Docker, no Kubernetes, no SSH keys in CI.

Your first deploy Install the .deb

Debian 13 on a KVM virtual machine · amd64 and arm64 · Apache-2.0 · Powered by Caddy

  1. git push
  2. CI builds app.tar.gz
  3. webhook
  4. motel swaps it liveZero downtime.

What happens when you push

  1. 1 · git pushYou push a commit to your app’s main. That is the whole deploy command.
  2. 2 · buildGitHub Actions builds the tarball and publishes it as a release, tagged with the commit’s first 12 characters.
  3. 3 · askThe run mints a short-lived OIDC token and asks your server to deploy. No secret is stored in CI.
  4. 4 · provemotel fetches the release, runs your migration, starts the new version on its own socket and health checks it for fifteen seconds. The old version serves every request meanwhile.
  5. 5 · liveTraffic moves to the new version. The old one finishes its requests and stops. The deploy step takes about half a minute.

If any step before the last fails, the old version never stopped serving, and the CI run goes red with the reason.

Not on GitHub? GitLab CI, any other CI with OIDC, or a key on a laptop can deploy too. The docs cover each.

One app is five rules and about twenty lines

motel builds no image and guesses nothing about your stack. It runs the command you name. Your app keeps five rules, and the server’s config says who may deploy it.

In your app

  1. Listen on the unix socket in $SOCKET. There is no port on the server.
  2. Answer GET /health with a 2xx once you can serve.
  3. On SIGTERM, finish the requests in flight and exit.
  4. Keep data in your shared/ directory. The release directory is replaced on every deploy.
  5. Put migrations in the command that runs before each version starts, and make them safe to run twice.

The example apps ship these rules as an AGENTS.md, for you and your coding agent.

listening on the socket
// Node / Express: server.listen() takes a path as well as a port.
server.listen(process.env.SOCKET ?? 3000);

// Deno: the `deno serve` CLI is port-only; call Deno.serve yourself.
const sock = Deno.env.get("SOCKET");
Deno.serve(sock ? { path: sock } : { port: 8000 }, handler);

// Go
ln, err := net.Listen("unix", os.Getenv("SOCKET"))

Bun, gunicorn, uvicorn, puma and axum bind a unix socket too. A framework CLI that only binds TCP, such as next start, needs a small server of your own in front. A runtime your app needs is installed under /usr on the server, or shipped inside the tarball, as the Node example does.

On the server

This is the app’s part of the example server config, comments removed. Adding a second app is another block like it, signed and pushed.

deploy.example.com/Caddyfile, in the server’s repository
{
	liveswap {
		artifact_allowlist api.github.com/repos/your-org/

		app example {
			command ./server
			pre_start ./migrate
			env APP_VERSION {version}
			env DATA_DIR {shared_dir}

			deploy_trust github {
				audience deploy.example.com
				claim repository your-org/example
				claim ref refs/heads/main
				claim workflow_ref your-org/example/.github/workflows/deploy.yml@refs/heads/main
			}
		}
	}
}

example.com {
	reverse_proxy {
		dynamic liveswap example
	}
}

deploy.example.com {
	liveswap_webhook
	box_webhook
}
command, pre_start
How the app starts, and the migration that runs before each version does.
artifact_allowlist
Where a deploy may fetch from: your organization’s release assets and nowhere else.
deploy_trust
Who may deploy it: one repository’s main branch and one workflow file, proven by the token GitHub mints for the run. There is no deploy key to leak.
dynamic liveswap
The proxy follows whichever version is live, so a deploy never touches the site block.

Your data is a directory

Each release is replaced on deploy; the app’s shared/ directory is not. motel tells the app where it is, and the app keeps its SQLite database and the files it stores there. For an app that fits on one server, that takes the place of a database server and object storage.

The database is a file.

SQLite, in the app’s own directory. Nothing to install, patch or give memory to, and no connection string that leaves the machine. Your migration runs before each new version starts.

Uploads are a folder.

Write files with the ordinary file API. No S3 client, no bucket credentials in the app, no signed URLs to hand out.

It’s private to the app.

Each app sees its own shared/ and nobody else’s. Another app on the same server cannot open your database, because in its view the file does not exist.

It leaves the server every hour.

Two lines say what to back up. The database is copied safely while the app runs. The bucket is yours, set up once for the server, and no app ever holds its key. A weekly drill fetches the newest snapshot of every app and checks it as a restore would.

The trade is one disk: if the server is lost, you restore from the last hourly backup. For most small apps that is the right trade, and it is the path where motel does everything for you. A restore into place backs up what is there first.

in the app’s block
app demo {
	env DATA_DIR {shared_dir}

	backup {
		sqlite app.db
		files  uploads
	}
}

# in the journal: every hour, and after the weekly drill
demo: ok: snapshot c4f0d7c1 holds sqlite app.db, files uploads
demo: restore proven: snapshot c4f0d7c1 was fetched and checked whole

# the day you need it
motel-backup restore demo

What’s in the package

The .deb is the server: Caddy with motel’s modules compiled in, and motel-backup beside it. Monitoring adds two of Debian’s own packages when you turn it on. The client is a separate download for your laptop. You would otherwise wire up a proxy, a deploy script, a rate limiter, a cache, a backup cron and an alerting stack yourself.

101

liveswap

Zero-downtime deploys, with a way back

Migrations run before each version starts. A version that fails its health check never gets traffic. The server keeps the five versions it deployed most recently, so rollback is a button in GitHub Actions. A watchdog restarts an app that crashes or stops answering its health check. Each app can have a memory and CPU cap, so one cannot starve the rest.

102

box

The server’s config and secrets, in git

The Caddyfile lives in a private repository of its own. The server applies a push only when every new commit is signed by a key on its list, and those keys stay on the signers’ laptops. A config that fails to load is rolled back. Secrets sit beside it, one file per value, encrypted with age to the server’s key and the signers’ keys. GitHub and CI only ever hold ciphertext.

103

backups

Hourly, off the server, proven weekly

Each app declares its SQLite databases and files. Every hour they go into a restic repository in a bucket you own. A weekly drill proves a restore would work, and motel-backup restore puts an app back.

104

penaltybox

Rate limiting your app steers

Your app knows which requests are expensive or suspicious, so it says so in an X-Rate-Limit-Level response header. motel keeps the weighted sliding-window budgets and answers 429 to clients that cross them, before they reach your app again.

105

cache

A page cache in front of your app

Standard HTTP caching by Souin, held in memory by Otter. Your app sets the cache headers; motel serves the repeats.

106

monitor

Alerts when something goes wrongExperimental

An app stuck restarting, a deploy that failed, a backup gone stale, a certificate that did not renew, a disk filling up: motel spots each one and Debian’s Alertmanager sends it to ntfy, Slack, Discord or any webhook that takes its JSON. With one more line, Debian’s VictoriaMetrics keeps each app’s numbers for 14 days and alerts on rules of your own. Neither opens a port on the server, and neither is installed until you ask. Since 0.7.0.

107

access

Read access for people, by ssh keyExperimental

A person line gives someone’s Ed25519 ssh key a read-only role on one app or on the whole server, with no account on it. They read status, deploys, alerts and numbers and, with a logs grant, logs. Nobody can deploy, roll back or push this way. Since 0.8.0.

Lobby

Caddy

Everything Caddy has

Certificates that issue and renew themselves, HTTP/2 and HTTP/3, the Caddyfile. motel is Caddy underneath, so moteld run, reload and validate behave exactly as Caddy’s do, and what you know about Caddy still applies.

Not a cluster. Not a container platform.

motel runs each app as a plain process in its own systemd sandbox, on one Debian 13 server, reached over a unix socket. There is no container runtime anywhere, which is why there is deliberately no Docker image. If you outgrow one server, you’ve outgrown motel. A good problem.

For you if

  • Your apps are a process and a directory: Node, Deno, Go, Python, Ruby, anything that can listen on a unix socket, with SQLite and files on local disk.
  • You want deploys from CI with no key stored in CI, and a server config that changes only by signed commit.
  • You want each app walled off from the others without running Docker.
  • You want backups whose restore is tested every week.
  • You know Caddy, or would like to. The config is a Caddyfile.

Not for you if

  • You deploy container images, or want a Dockerfile or buildpack built for you. motel has no container runtime.
  • You want a web dashboard or one-click databases. motel’s client is a terminal program that only reads, and motel does not install or manage a database server.
  • Your server is not Debian 13 on KVM. The package refuses Debian 12 and Ubuntu 24.04, and motel refuses to run apps on LXC-style hosts.
  • You need a second server, or failover.
  • You need someone to call. One person maintains motel, and there is no support, paid or free.

Your apps, from your laptop

Type motel on your laptop and the server’s apps are on your screen: what is running, what needs a look, what the last deploy did. It reads over HTTPS with a token your own ssh key signs. No ssh session, no account on the server, no dashboard to host. Experimental

Every app your key may view, sorted by what needs a look. The strip under the title says why the first one does.
One app: its state, the alerts it holds, memory against its cap, and every deploy with who made it.
Why a deploy failed: the phase it reached, what the health check answered, and the app’s last lines. The server replaces the values of the app’s secrets before the lines leave it.
The app’s own lines, followed as they arrive, with a marker where each release starts. The operator grants logs separately from everything else.
Memory and CPU over an hour, a day, a week or two weeks, drawn in the terminal, with each successful deploy marked on the axis. Needs the monitor block’s metrics line on the server.
Everything the server’s Alertmanager holds, and what has been silenced, for someone allowed to view the whole server.

Screens captured from the client’s sample mode, motel --demo, which reads no server. Names and figures are sample data.

Worst first.

The list opens sorted by attention: a restart loop, a failed deploy or a deploy in flight comes before everything that is fine.

Your own ssh key, reads only.

The operator adds two lines to the server’s config: your key, and what it may read. The key is Ed25519; a hardware key works. Nothing the client reaches can deploy, roll back or change the config, and you get no account on the server.

Every screen is a command.

Press c for the command behind what you are looking at, and y for the server’s answer as JSON. Scripts use the same reads:

motel status blog --follow
motel deploys blog
motel logs blog --follow
motel metrics blog --range 24h
motel monitor alerts --app blog
motel status blog --json

Getting it.

On the releases page beside the server, for an M-series Mac and for Linux on amd64 and arm64. Anything else builds it from a clone.

Security

A stolen GitHub login can ship a new version of an app it can push to. That version sees that app’s own data and secrets, and nothing else on the server. It cannot change the server’s config: that takes a commit signed by a key that stays on a signer’s laptop. Read the threat model.

Every app is sandboxed, with no opt-out.

Each app sees its own release, its own data and a private /tmp. Other apps and motel’s keys are absent from its filesystem and its process table, not merely unreadable.

No deploy key, in CI or on the server.

A deploy carries a short-lived token from CI, verified against the provider’s public keys. Nothing an attacker can steal off the server lets them deploy.

The admin API is a unix socket, not a port.

“Localhost only” would include every app you run, and one SSRF bug could reconfigure the server.

motel cannot change its own config.

motel runs unprivileged. Only root installs the config, and only from a commit signed by a key the running config already names.

What apps share: one user and the network.

Apps run as one Unix user and share the server’s network. The sandbox keeps them apart, not the user account, and motel refuses to run apps on a host that cannot provide it. An app can make outbound calls and open a port of its own, so keep the provider’s firewall shut to everything but 80 and 443. Giving each app a user of its own is on the roadmap.

Questions

What can I run on it?

Anything that listens on the unix socket motel hands it, answers a health check and stops cleanly. The examples are a Node single executable, which needs no runtime on the server, and a Deno app whose permission flags are held in the server’s config, where a compromised build cannot widen them.

What if a deploy goes wrong?

A version whose migration fails or whose health check never passes does not get traffic; the one that was serving keeps serving. The failed step in CI shows which stage refused it and the last 40 lines your app wrote. Once traffic has moved, nothing reverts by itself: the watchdog restarts the same version, and going back is the rollback button.

Is anything not zero-downtime?

Upgrading motel itself. The process that listens on 80 and 443 is the one being replaced, so new visitors get errors for about a tenth of a second, or longer while a slow request finishes. Your apps are not restarted. Deploys and config changes drop no requests.

Which servers does it support?

Debian 13 on a real virtual machine; providers call it KVM. Container-style hosts such as LXC usually cannot provide the per-app sandbox, and motel refuses to run apps there rather than run them with something weaker.

Can I use Postgres or MySQL?

Yes, but you run it. An app can reach a database on the same server over loopback, or one elsewhere over the network. motel does not install, manage or back up a database server. SQLite in the app’s shared/ directory is the path where migrations, backups and restores are done for you.

Where do backups go?

Into one restic repository in an S3-compatible bucket you own, set up once for the server. The whole procedure has been run end to end on Backblaze B2; AWS S3 and Hetzner are documented but have not been run. The server’s own report is only as honest as the server, so the guide has you look from your own machine with restic at least every 90 days. Backups has the whole procedure, restores included.

Do I have to use GitHub Actions?

No. The tutorial uses it, but the server also takes a deploy from GitLab CI, from any other CI with OIDC, or from a laptop with a key. Deploying from outside GitHub covers each.

What does it cost to run?

motel is free, under Apache-2.0. You pay for the server and the backup bucket. On the project’s own server, a Hetzner arm64 machine with 3.8 GB, measured over a day in November 2026, motel held 63 to 67 MB of memory. Turning alerts on adds Alertmanager at about 42 MB. Turning metrics on adds VictoriaMetrics at 174 to 191 MB, capped at 384 MiB, and vmalert at 28 MB. The weekly restore drill downloads each app’s data once, about 4.3 times the apps’ size a month.

What is experimental?

The monitor block, since 0.7.0, and people’s read access and the laptop client, since 0.8.0. What each reads or sends may change until a release’s notes say otherwise. Deploys, the config repository, the rate limiter, the cache and backups are not.

How do I leave?

Your app is a tarball and a command, and one line makes it listen on a port again. Your data is a directory of files on the server. Your backups are an ordinary restic repository: with its address, storage key and password, restic reads them from any machine. The config is a Caddyfile. Removing the package leaves your apps’ releases and data where they are.

Who makes it, and is there support?

One person. There is no support, paid or free. Questions and bug reports go to GitHub Discussions and are answered when time allows. Security reports go through GitHub’s private reporting and are acknowledged within a few days. Every release is blocked until the full test matrix passes, which includes installing the real .deb under systemd on Debian 13 on both architectures.

Check in in four steps

From a fresh server to an app that deploys on every push. The tutorial uses the same example repositories the end-to-end tests build and deploy on every change, so what it says works. On your laptop you need git 2.34 or later, make, ssh, curl and motel’s laptop client. The GitHub CLI is optional.

  1. 1

    A server

    A Debian 13 virtual machine of the KVM kind; the cheapest tier is enough for a few small apps. Open TCP ports 80 and 443 (and UDP 443 for HTTP/3) and point two DNS names at it: one for the app, one for deploys.

  2. 2

    Install motel

    Run this as root on the server. It fetches the latest release for the server’s architecture, checks it against the published checksums and installs it. You get the server, moteld, running as a systemd service, and a starter config. motel fetches its own certificates.

    as root, on the server
    v=$(curl -fsSL -o /dev/null -w '%{url_effective}' \
      https://github.com/smallhoursorg/motel/releases/latest)
    v=${v##*/v}
    arch=$(dpkg --print-architecture)
    base=https://github.com/smallhoursorg/motel/releases/download/v$v
    mkdir -p /var/local/motel && cd /var/local/motel
    curl -fsSLO "$base/moteld_${v}_${arch}.deb" &&
      curl -fsSLO "$base/checksums.txt" &&
      sha256sum -c --ignore-missing checksums.txt &&
      apt-get update && apt install ./moteld_${v}_${arch}.deb
    systemctl enable --now moteld
    
    curl -s localhost
    moteld is running. To serve your apps: moteld init …
  3. 3

    The server’s config, in git

    Create a private repository from the box template and add your ssh key as its first signer. Then tell the server, once, which repository its config comes from. From then on the config changes by signed push, and nothing on the server is edited by hand.

    on your laptop
    gh repo create your-org/boxes \
      --template smallhoursorg/motel-example-box --private --clone
    cd boxes
    motel signer add
  4. 4

    The app

    Create your app from the Node or Deno template and set one variable, MOTEL_URL. No file is edited. Re-run the first workflow run, or push, and it deploys. An arm64 server takes one more variable and one package; the tutorial says which.

    on your laptop
    gh repo create your-org/example \
      --template smallhoursorg/motel-example-node --private
    gh variable set MOTEL_URL -R your-org/example \
      --body https://deploy.example.com/example
    
    # when the run is green
    curl https://example.com/
    hello from 2aafbe9d37c8 (schema v1)

What you have at the end

An app that deploys on every push to its main, and a server whose config changes on every signed push to its own repository, with no SSH key, password or token stored anywhere in CI. Rollback is a button. The next app is one more block in the Caddyfile and one more repository from the template.

Installing and upgrading need root. Everyday administering does not: the config changes only by signed push.

Follow the tutorial All releases Upgrading

Built on

motel is mostly other people’s work, put together with care. These are the parts, and what each does here. The README lists every dependency, what requires it and why.

Caddy

The foundation. motel is a Caddy distribution: HTTPS, HTTP/2 and HTTP/3, the Caddyfile and the reverse proxy are Caddy’s.

Souin, with Otter

The page cache, and the in-memory store behind it.

restic and sqlite3

The backups. Both are Debian’s own packages; motel-backup runs them.

age

The encryption for secrets kept in git.

systemd

Each app is a systemd unit, and the sandbox around it is systemd’s. That is why motel needs systemd 257, and so Debian 13.

Alertmanager

Debian’s prometheus-alertmanager routes and sends the alerts.

VictoriaMetrics

Debian’s victoria-metrics, with vmalert, keeps the numbers and checks the rules.

tview and tcell

The client’s screens.