Skip to content

Moorage 0.3.0

Choose a tag to compare

@github-actions github-actions released this 04 Nov 05:32
· 138 commits to main since this release
730533f

Moorage 0.3.0 has a web console. Everything you run with moor you can now see and do at the server's console address: deploy, scale, restart and roll back apps; watch a deployment's stages and log as they happen; follow and search logs; change variables; manage your keys and tokens, and, as an administrator, users and registries. Every page works without scripts, on a phone, and in Chromium, Firefox and WebKit, which CI now drives for real. It also installs in one line, and gains moor scale, moor redeploy and moor password.

Upgrading from 0.2.0 needs no steps of its own: replace moor and restart the server, and running apps are taken over without a restart. Two things take a little more or a little less room from now on: an upload's source is kept beside its build for moor redeploy, until the build is collected; and the logs of instances that stopped more than 14 days ago are removed.

Added

  • Logs in the console (wave 3, slice 4). Every instance's output, live, merged by time: by process or instance, time range, text and source, with an app's builds, requests and events a click away, and only its problems at another. A line that is a JSON object reads as its message and fields, and errors and warnings stand out. Pause, wrap, older lines and download. moor logs and the API have the same: --source, --grep, --since, --until, --instance and --problems.

  • Variables in the console. With where each comes from, and whether something overrides it. Change one and it is released; or save it and release it later, which the page keeps saying. Edit as text takes a whole .env and says what it would change before it does.

  • Your account in the console. Your password, SSH keys, API tokens, each with what it can do, for which apps and until when, and your sessions. moor password, and POST /api/v1/me/password: it ends your other sessions.

  • Settings for administrators. What server.toml says; users, with invitation links, roles and disabling; registries' credentials; and a System page with what moor server doctor finds, also at GET /api/v1/server/doctor.

  • Apps and deployments in the console (wave 3, slice 3). The apps list says how each app stands. An app's page has its instances and their health, its deployments and activity, and Deploy, Redeploy, Restart, Roll back and Scale. A deployment's page shows its stages and log as they happen, the resolved manifest and what changed since the release before: of variables, their names only. New app says how to deploy one; a source archive or an image can be deployed from the page. See the console.

  • moor scale web=3 worker=1. How many instances of each process run: new ones start beside those running, those beyond the number finish their requests and stop, and an instance that cannot start leaves the app as it was. The number stays, over the manifest's instances, for the releases to come. In the API: PATCH /api/v1/apps/{app}/envs/{env}. Planned for 0.5.0, and here because the console needed it.

  • moor redeploy. Builds again what the current release was built from: the same commit, upload or image name. For this, a build now keeps a copy of its upload, or of an image's manifest, as source.tar.gz beside it, until the build is collected; a release built before this version cannot be redeployed, and says so. A release uploaded ready to run has nothing to build.

  • moor releases show vN and moor releases diff vN vM. What a release runs, and what changed between two.

  • Every deployment has a log. A rollback, a change of variables and an upload ready to run wrote none.

  • The web console begins (wave 3, slice 2). Signing in now leads to the console: the apps, with their addresses and releases; Activity, a timeline of what happened; and Getting started, which says how the server looks, what to install and how to deploy, and watches for your first deployment. Pages update as things happen, over one stream of events. ⌘K or Ctrl+K jumps to an app, a page or an action. It has light and dark themes that follow the system or your choice, works at phone width, meets WCAG AA contrast, and works without scripts: every page is plain HTML and forms, under a strict Content-Security-Policy with no inline scripts or styles. See The web console.

  • Events. Deployments, releases, changes of variables (their names, never their values), instances that exit, sicken and recover, and the server starting are recorded for 90 days. moor events shows them and -f follows them; GET /api/v1/events lists them and GET /api/v1/events/stream follows them as server-sent events, catching up after a reconnection. A token restricted to an app sees only that app's.

  • One line to install (wave 3, slice 1). curl … install.sh | sh on macOS and Linux, and irm … install.ps1 | iex in PowerShell on Windows 11. Each picks the file for the computer from the latest release, requires exactly one matching SHA-256 checksum, runs the downloaded program's version check, and only then puts it in place, so a failed download never replaces a working copy. Neither needs administrator rights: moor goes to ~/.local/bin, or to /usr/local/bin as root, or on Windows to %LocalAppData%\Programs\Moorage, which is added to the user PATH. Running one again upgrades moor without disturbing a running server or its apps, including on Windows, where the running file is moved aside; MOOR_VERSION installs a particular release. See Installing Moorage.

Changed

  • moor logs reads more. With --source it adds an app's builds, requests and events to its instances' output. A line that is a JSON object prints as its message and fields; --json still has the line as written.
  • A rollback, a change of variables and an upload ready to run now write a log, like any other deployment.
  • Scaling comes earlier than planned. The roadmap had it in 0.5.0; the console needed it.