Skip to content

mm 0.1.3

Latest

Choose a tag to compare

@github-actions github-actions released this 26 Nov 23:21
· 1 commit to master since this release
1adc6d1

Remote protocol: 1. Every change in this release is additive: mm 0.1.3
works with hosts on 0.1.2, and hosts on 0.1.3 keep serving mm 0.1.2. The
faster cluster deploys and node metrics need every node upgraded
(mm target setup plan --upgrade); until then a deploy keeps the older
rollout steps, and its plan names the nodes still behind.

Changed

  • mm update restarts the local user services that run mm (the dashboard
    control API under systemd or launchd) and checks they come back, lists
    mm mcp serve processes still on the old release, and, run in a project,
    ends with the release each remote environment's nodes run and the setup plan
    command for each environment with an older node.

  • The development environment on this machine runs without Compose health
    checks, so a code change that breaks a service no longer fails each
    mm dev up. environments.<name>.healthchecks turns them on there, or off
    anywhere else; service_healthy dependencies then wait for
    service_started, and mm service status shows check off.

Added

  • mm mcp serve has mm_service_restart_plan and mm_service_restart_apply:
    an agent with operate in an environment restarts one service from a
    reviewed plan, through the same path as mm service restart; below
    operate it hands the user that command. mm_access lists what each
    grant allows under allows.

  • mm_read kind env returns what mm env status prints, or one variable
    with key, never with a sensitive variable's value; kind secrets takes
    key too, and health adds the readiness checks mm doctor lists for an
    environment on this machine.

  • Prometheus metrics from every cluster node: networks.<name>.metrics: true
    has each node serve its host (CPU, memory, load, filesystems, disks,
    interfaces), mesh and service metrics at http://mmd.internal:9753/metrics
    to that network's containers, with that environment's services only. The
    host policy's metrics: can turn it off, require a bearer token, or serve
    every project to the other hosts on the mesh address with a token of its
    own. See
    docs/how-to/metrics.md.

  • mm secret status shows when each secret's current revision was set and
    who set it, in SET and BY columns, and as set_at_unix_ms and set_by
    in JSON when known. mm records the writer (team user, login name, or
    agent:NAME (USER) through mm mcp) in the Age store and in OpenBao and
    Vault custom metadata; the terminal UI shows the same for a selected
    secret variable. mm 0.1.2 still reads an Age store this release wrote.

  • Cluster deploys spend less time waiting on each node: a rollout prepares
    its environment once instead of for every stack, a health wait renders the
    Compose project once and looks again within a second, a node checks every
    image of a stack in one look and pulls up to three at once, drained
    containers stop side by side, and the client checks every 250 ms that the
    other nodes resolve new containers.

  • A service that runs on more than one node of a cluster and sets no
    update.order now starts its new container before the old one stops,
    unless it publishes a host port, sets container_name, uses the host's
    network, mounts a writable volume or runs several containers per node;
    update.order: stop-first keeps the old order. A deployment goes on as soon
    as every node stops sending a replaced container new requests, and the
    container drains and stops in the background, so drain no longer adds to
    deploy time. The next deploy counts a container that still drains as
    neither the old nor the new one, so going back to the image it runs starts
    a new container of that image.

  • A cluster node leaves a stack alone when its containers already run what
    the deployment would start: the same Compose configuration, environment and
    secrets, the image its tag names on the node, healthy, and as many as the
    node runs, not counting containers that still drain from the deploy before.
    Nothing is stopped, started or waited for. Docker hosts only; a Podman host
    applies every stack as before.

  • A cluster deploy has every node pull the images it runs, all nodes at the
    same time, before any node is replaced; a pull that fails stops the deploy
    with nothing changed. Unless every node's mmd says it knows the new
    rollout steps (rollout_steps in mm target nodes --output json), nodes
    keep pulling stack by stack, and the plan names the older nodes until
    mm target setup plan --upgrade brings them up to date.

  • A stack whose services that run on several nodes all start first is
    replaced on all its nodes at once when no service sets update.parallelism;
    otherwise it still goes one node at a time. An update.parallelism a
    service sets keeps applying.

  • Stacks that after: does not order roll out side by side in a cluster
    deploy: each node rolls out up to four of them at once in one step, and the
    next layer of after: starts once every node resolves what they started. A
    stack with before-deploy jobs, services that pause on failure, or more than
    one batch of nodes still rolls out alone. The plan lists the stacks that go
    side by side. With a node whose mmd does not know the new steps, stacks
    roll out one at a time, and the plan says so.

  • With MM_TIMING=1, mm deploy apply on a cluster shows how long the
    networks, storage, pull, each wave of stacks, each node step and the finish
    took, and mmd shows each stack's leave, start, health wait and resolve.
    scripts/live-timing.sh --deploy times a changed and an unchanged deploy
    against a budget, with examples/cluster-heavy as the load.

  • On Docker Engine 25 and later, mm's generated Compose overlay gives each
    service with a health check start_interval: 1s, and a start_period of
    interval times retries when the service sets none, so a deploy sees a
    new container healthy within about a second instead of after the first
    interval. The service's own interval applies once the container is
    healthy. The first deploy after upgrading recreates every service with a
    health check once, since its configuration changes. Podman hosts and older
    Docker Engines are left as they are.

  • Every node of a cluster deploy finishes at the same time, and nodes without
    stacks begin at the same time. A node whose finish fails rolls itself back
    as before, but the other nodes may have finished already: the report lists
    them as applied instead of rolling them back.

Fixed

  • mm_read kind secrets for an environment on this machine returned every
    field as [REDACTED]; it now lists each secret's key, provider, status and
    revision under bindings.

  • mm secret status shows default instead of unset for a secret that is
    not stored when every variable that reads it falls back to a non-empty
    .env.example default, for this machine's store and for remote hosts
    (live: default). JSON keeps "status": "unset" and adds
    "defaulted": true.

  • A plan whose config-file template reads a release input it was not given
    fails with MM_RELEASE_INPUT, as one whose environment file does, instead
    of MM_ENVIRONMENT.

  • On Linux, mm ingress stop keeps the public forwarder stopped across reboots
    and deploys, so a reverse proxy you run on ports 80 and 443 in front of mm's
    Traefik no longer makes mm dev up fail or ask for sudo. mm ingress status
    reports that state and Traefik's loopback ports.

  • The apply command a cluster mm target setup plan prints carries every
    flag the plan was made with that apply needs again: --upgrade,
    --downgrade, --commit, and --trust-new-host-keys when the plan
    replaces a host key. A --format json plan lists them under flags.

  • A job run that could not be prepared, such as a manual run started after the
    environment's values changed, no longer stays launching and blocks every
    later deployment and mm job history with MM_STATE: it ends failed with
    the reason as its output. A deployment's sweep and reads of the runs go on
    past a run they cannot move on, and mm job cancel ends a run at once.

  • A rollback no longer checks the routes of stacks it left alone, so a stack
    that was already stopped no longer turns a failed deployment into "mutation
    state: unknown".