Skip to content

Releases

v0.6.0

Choose a tag to compare

@github-actions github-actions released this 17 Nov 23:15
9cfa118
  • portainer: an agent registers itself as an environment on a Portainer server. Set
    portainer_agent_register_url (the server, e.g. https://portainer.example.com) and
    portainer_agent_register_api_token (an access token; the run fails before any change when it is
    empty); portainer_agent_register_address pins the URL's host name to an address (curl
    --resolve, IPv6 allowed, TLS is still verified), portainer_agent_register_name (default the
    inventory host name) names the environment and portainer_agent_register_endpoint (default the
    first portainer_agent_bind address, port 9001) is where the server dials the agent. The
    environment is matched by exact name: missing is created (retried while the agent starts), the
    same name with the same endpoint is left alone, and the same name with another endpoint fails
    the run naming both and changes nothing. Nothing is created in check mode. The token only lives
    in a temporary 0600 header file that curl reads and that is removed afterwards, never on a
    command line or in the output. An existing environment of another name for the same agent is
    not detected (the match is by name only). Removing or editing environments is not handled; the host needs
    curl (the base role installs it).
  • tailscale: the first login gives up after tailscale_login_timeout seconds (default 120)
    instead of waiting forever. The run then fails with what tailscale up reported or, when the
    tailnet requires device approval, names the node to approve in the admin console. The auth key
    file is removed either way.
  • Releases are cut by the release workflow (Actions tab, bump patch, minor or major, dry_run
    on by default): it checks main, CI, the signed test run and the changelog, then bumps
    galaxy.yml and CHANGELOG.md, tags vX.Y.Z, publishes the release, updates the README
    install example and announces it on Discord. The steps by hand stay in CONTRIBUTING.md.
  • nginx: new role that installs nginx of one stable series from nginx.org (nginx_version, a
    quoted major.minor such as "1.30"; Ubuntu 24.04 and 26.04, any other release is refused
    before any change) and serves the sites of nginx_sites, the complete list: a site that leaves
    it loses its config, while its web root, logs and certificate stay. An apt pin keeps nginx in the
    series and Ubuntu's nginx packages out; the nginx.org origin joins unattended-upgrades. An
    installed nginx of another series, or Ubuntu's, is refused before any change. A site is a PHP
    site (php_pool, fastcgi to /run/php/<pool>.sock; only php_front_controller and
    php_scripts run, any other .php file answers 404), a proxy site (proxy, with WebSocket
    upgrades) or a static site; www-data joins each site's group, so web roots must be
    group-readable. TLS is letsencrypt (certbot, nginx_acme_email, HTTP-01 through a webroot,
    renewals reload nginx), off, or {cert, key} with OCSP stapling through nginx_resolvers
    (127.0.0.53, so other hosts than systemd-resolved ones set it). Global hardening: TLS 1.2 and
    1.3 with Mozilla's intermediate ciphers, server_tokens off, and a default server that closes
    the connection for an unknown host name. Per site: security headers and HSTS, 404 for dotfiles,
    composer.json and dumps (hardening), rate_limit zones (answer 429), basic_auth with an
    allowlist (nginx_real_ip_from for trusted proxies; the controller needs passlib), headers
    and extra. Every config change is tested with nginx -t before nginx reloads, and a config
    nginx rejects is put back. The noix error pages (nginx_error_pages, on by default, so the host
    needs Docker unless it sets false) answer nginx's own errors only; an app's own error pages
    pass through. A site with anubis: true is checked by the anubis role in host mode on
    127.0.0.1:nginx_anubis_port (keep it equal to anubis_host_port); a site cannot have both
    anubis and basic_auth, and 401 must not be among nginx_error_pages_codes while a site has
    Anubis. Deploy snippets (user_includes, nginx_user_includes, nginx_include_user) are not
    supported yet and are refused. nginx_ipv6 ignores link-local addresses.
  • nginx: a link is followed only to a file of its own owner in every part of a path, the web
    root's own path too (disable_symlinks if_not_owner without from=): a site user's link in its
    root path (a deploy's current) re-pointed at another site's tree is not served. A deploy's
    current -> releases/N works when the site user owns both; a root reached through a link of one
    owner to another owner's tree is not served, so use the real path or a link of the same owner.
  • nginx: the global config (nginx.conf, the default server, the hardening) is written and
    tested with the site configs in one nginx -t, and put back with them when nginx rejects the
    config: a rate limit zone or an nginx_http_extra definition leaves in the same run as the site
    that stops using it.
  • nginx: a Let's Encrypt certificate whose renewal config names another ACME server than
    nginx_acme_server is reissued from nginx_acme_server on the next run, so a switch from
    Let's Encrypt's staging directory to production replaces the staging certificates.
  • nginx: hardened sites also answer 404 for compressed dumps and backups (*.sql, *.bak and
    *.swp with .gz, .bz2, .xz, .zst, .zip, .7z, .lz4 or .lzma, in any case).
  • nginx: a site with the user or group www-data, or with a privileged group (root, sudo,
    admin, wheel, adm, shadow, disk, kmem, docker, lxd, incus-admin, libvirt,
    systemd-journal), is refused before any change: www-data joins a site's group, so every
    nginx worker would get it.
  • nginx: a failed certificate request says what each site serves until a run gets it: a site
    with a certificate keeps its TLS block, a site without one (new, or switched to letsencrypt)
    only its HTTP block, the ACME challenges and a redirect to HTTPS, none of its content.
  • anubis: new mode host for an nginx on the host itself (the nginx role's sites with
    anubis: true): the container publishes 127.0.0.1:anubis_host_port (8923) only and joins none
    of the other modes' networks. One mode per host.
  • php: new role that installs PHP versions from the ondrej/php PPA (Ubuntu 24.04 only for now; any
    other release is refused before any change) and runs every pool in php_pools as a PHP-FPM
    master of its own (php-fpm@<name>, socket /run/php/<name>.sock without a version in it,
    owned by the pool user and php_fpm_listen_group). A config change reloads only that pool, a
    version change restarts only that pool. Each pool has /php-fpm-ping (pong) and
    /php-fpm-status. php_pools is the complete list: a pool that leaves it is stopped and its
    config removed; its tmp_dir and log stay. Versions that leave php_versions stay installed,
    with their php<v>-fpm service stopped. With php_fpm_per_pool_service: false (classic mode)
    the pools run in the packages' php<v>-fpm services instead, and switching moves every pool.
    Pool env values starting with $ are refused (FPM would expand them), a changed socket owner
    or listen group restarts the pool, and a config FPM rejects never replaces a running one: it is
    tested before anything is switched. Pool env and ini values never appear in the run's output.
    A pool with group root (gid 0) and pool names longer than 64 characters are refused before any
    change. tmp_dir and its session, upload and sys dirs are created without following
    links (the three dirs as the pool user): a link in tmp_dir or its path stops the run, naming
    it. A run that fails after a change, for example on a typo in one version's extensions, still
    reloads or restarts the pools for what it changed before it fails. Ubuntu's php<v>-*
    packages are pinned to -1 and the PPA preferred, so a run that cannot reach the PPA never
    installs Ubuntu's PHP. The PPA joins
    unattended-upgrades in both modes; with one master per pool an apt hook restarts the pools of
    each version with an upgraded php<v>-* package (extensions too) one at a time
    (/usr/local/sbin/php-fpm-rolling-restart). Each restart is bounded by
    php_fpm_restart_timeout; a pool that does not come back stops the rolling restart (see
    journalctl -t php-fpm-rolling-restart) while apt still succeeds. needrestart, installed by
    default on Ubuntu servers, is told to leave the php-fpm@ pools to that hook
    (/etc/needrestart/conf.d/50noixdev-php-fpm.conf) instead of restarting them all at once. In
    classic mode the package's own restart applies, needrestart's included.
  • composer: new role that installs Composer as /usr/local/bin/composer from the official phar
    at an exact version (composer_version) checked against a pinned SHA-256 (composer_sha256,
    from getcomposer.org's .sha256sum; a wrong checksum leaves the installed Composer alone),
    Composer 1 as /usr/local/bin/composer1 with composer1_enabled, and ~/.config/composer/auth.json
    for the users in composer_auth (mode 0600, written as the user, content never printed). The role
    owns the whole file; state: absent removes it. A user listed twice, an unknown user and a
    present entry without auth are refused. It needs a php on the host and installs
    ca-certificates.
  • portainer, traefik, dashy, pulsix_manager, pulsix_worker, dns, harbor, listmonk,
    anubis and mailcow check for Docker first, before they change anything: the docker CLI,
    the compose plugin (docker compose version) and a daemon that answers (docker version).
    Without them the run fails with "Docker is not installed or not running on ; run
    noixdev.infra.docker (or install Docker with the compose plugin) before " and the reason,
    instead of a module error later in the role. The r...
Read more