diff options
Diffstat (limited to 'nixos')
21 files changed, 337 insertions, 58 deletions
diff --git a/nixos/doc/manual/development/releases.xml b/nixos/doc/manual/development/releases.xml index dcedad540e1f..f45fecd16c35 100755 --- a/nixos/doc/manual/development/releases.xml +++ b/nixos/doc/manual/development/releases.xml @@ -177,6 +177,12 @@ </listitem> <listitem> <para> + Update "Chapter 4. Upgrading NixOS" section of the manual to match + new stable release version. + </para> + </listitem> + <listitem> + <para> Update http://nixos.org/nixos/download.html and http://nixos.org/nixos/manual in https://github.com/NixOS/nixos-org-configurations diff --git a/nixos/doc/manual/installation/installing.xml b/nixos/doc/manual/installation/installing.xml index f4f8d470f802..9687c21a01e6 100644 --- a/nixos/doc/manual/installation/installing.xml +++ b/nixos/doc/manual/installation/installing.xml @@ -54,7 +54,7 @@ <para> To manually configure the network on the graphical installer, first disable - network-manager with <command>systemctl stop network-manager</command>. + network-manager with <command>systemctl stop NetworkManager</command>. </para> <para> diff --git a/nixos/doc/manual/installation/upgrading.xml b/nixos/doc/manual/installation/upgrading.xml index 69668b1d4bd6..35b4d266e12e 100644 --- a/nixos/doc/manual/installation/upgrading.xml +++ b/nixos/doc/manual/installation/upgrading.xml @@ -14,11 +14,11 @@ <para> <emphasis>Stable channels</emphasis>, such as <literal - xlink:href="https://nixos.org/channels/nixos-17.03">nixos-17.03</literal>. + xlink:href="https://nixos.org/channels/nixos-19.03">nixos-19.03</literal>. These only get conservative bug fixes and package upgrades. For instance, a channel update may cause the Linux kernel on your system to be upgraded - from 4.9.16 to 4.9.17 (a minor bug fix), but not from - 4.9.<replaceable>x</replaceable> to 4.11.<replaceable>x</replaceable> (a + from 4.19.34 to 4.19.38 (a minor bug fix), but not from + 4.19.<replaceable>x</replaceable> to 4.20.<replaceable>x</replaceable> (a major change that has the potential to break things). Stable channels are generally maintained until the next stable branch is created. </para> @@ -38,7 +38,7 @@ <para> <emphasis>Small channels</emphasis>, such as <literal - xlink:href="https://nixos.org/channels/nixos-17.03-small">nixos-17.03-small</literal> + xlink:href="https://nixos.org/channels/nixos-19.03-small">nixos-19.03-small</literal> or <literal xlink:href="https://nixos.org/channels/nixos-unstable-small">nixos-unstable-small</literal>. @@ -63,8 +63,8 @@ <para> When you first install NixOS, you’re automatically subscribed to the NixOS channel that corresponds to your installation source. For instance, if you - installed from a 17.03 ISO, you will be subscribed to the - <literal>nixos-17.03</literal> channel. To see which NixOS channel you’re + installed from a 19.03 ISO, you will be subscribed to the + <literal>nixos-19.03</literal> channel. To see which NixOS channel you’re subscribed to, run the following as root: <screen> # nix-channel --list | grep nixos @@ -75,13 +75,13 @@ nixos https://nixos.org/channels/nixos-unstable # nix-channel --add https://nixos.org/channels/<replaceable>channel-name</replaceable> nixos </screen> (Be sure to include the <literal>nixos</literal> parameter at the end.) For - instance, to use the NixOS 17.03 stable channel: + instance, to use the NixOS 19.03 stable channel: <screen> -# nix-channel --add https://nixos.org/channels/nixos-17.03 nixos +# nix-channel --add https://nixos.org/channels/nixos-19.03 nixos </screen> If you have a server, you may want to use the “small” channel instead: <screen> -# nix-channel --add https://nixos.org/channels/nixos-17.03-small nixos +# nix-channel --add https://nixos.org/channels/nixos-19.03-small nixos </screen> And if you want to live on the bleeding edge: <screen> @@ -127,7 +127,7 @@ nixos https://nixos.org/channels/nixos-unstable current channel. (To see when the service runs, see <command>systemctl list-timers</command>.) You can also specify a channel explicitly, e.g. <programlisting> -<xref linkend="opt-system.autoUpgrade.channel"/> = https://nixos.org/channels/nixos-17.03; +<xref linkend="opt-system.autoUpgrade.channel"/> = https://nixos.org/channels/nixos-19.03; </programlisting> </para> </section> diff --git a/nixos/doc/manual/man-nixos-build-vms.xml b/nixos/doc/manual/man-nixos-build-vms.xml index 87e4f3dae869..7d6e04e0dd90 100644 --- a/nixos/doc/manual/man-nixos-build-vms.xml +++ b/nixos/doc/manual/man-nixos-build-vms.xml @@ -24,8 +24,14 @@ <arg> <option>--help</option> - </arg> - + </arg> + + <arg> + <option>--option</option> + <replaceable>name</replaceable> + <replaceable>value</replaceable> + </arg> + <arg choice="plain"> <replaceable>network.nix</replaceable> </arg> @@ -115,6 +121,18 @@ </para> </listitem> </varlistentry> + <varlistentry> + <term> + <option>--option</option> <replaceable>name</replaceable> <replaceable>value</replaceable> + </term> + <listitem> + <para>Set the Nix configuration option + <replaceable>name</replaceable> to <replaceable>value</replaceable>. + This overrides settings in the Nix configuration file (see + <citerefentry><refentrytitle>nix.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>). + </para> + </listitem> + </varlistentry> </variablelist> </refsection> </refentry> diff --git a/nixos/doc/manual/release-notes/rl-1909.xml b/nixos/doc/manual/release-notes/rl-1909.xml index 43946ba6df2a..3bdfc5c17631 100644 --- a/nixos/doc/manual/release-notes/rl-1909.xml +++ b/nixos/doc/manual/release-notes/rl-1909.xml @@ -110,6 +110,13 @@ DynamicUser mechanism</link> which obviates these options. </para> </listitem> + <listitem> + <para> + The NetworkManager systemd unit was renamed back from network-manager.service to + NetworkManager.service for better compatibility with other applications expecting this name. + The same applies to ModemManager where modem-manager.service is now called ModemManager.service again. + </para> + </listitem> </itemizedlist> </section> diff --git a/nixos/modules/config/system-path.nix b/nixos/modules/config/system-path.nix index 7a65e44e828d..fae2fc740082 100644 --- a/nixos/modules/config/system-path.nix +++ b/nixos/modules/config/system-path.nix @@ -7,7 +7,7 @@ with lib; let - requiredPackages = map lib.lowPrio + requiredPackages = map (pkg: setPrio ((pkg.meta.priority or 5) + 3) pkg) [ config.nix.package pkgs.acl pkgs.attr diff --git a/nixos/modules/installer/tools/nixos-build-vms/nixos-build-vms.sh b/nixos/modules/installer/tools/nixos-build-vms/nixos-build-vms.sh index 4e981c074a57..25106733087e 100644 --- a/nixos/modules/installer/tools/nixos-build-vms/nixos-build-vms.sh +++ b/nixos/modules/installer/tools/nixos-build-vms/nixos-build-vms.sh @@ -9,49 +9,44 @@ showUsage() { # Parse valid argument options -PARAMS=`getopt -n $0 -o h -l no-out-link,show-trace,help -- "$@"` +nixBuildArgs=() +networkExpr= -if [ $? != 0 ] -then - showUsage - exit 1 -fi - -eval set -- "$PARAMS" - -# Evaluate valid options - -while [ "$1" != "--" ] -do +while [ $# -gt 0 ]; do case "$1" in - --no-out-link) - noOutLinkArg="--no-out-link" - ;; - --show-trace) - showTraceArg="--show-trace" - ;; - -h|--help) - showUsage - exit 0 - ;; + --no-out-link) + nixBuildArgs+=("--no-out-link") + ;; + --show-trace) + nixBuildArgs+=("--show-trace") + ;; + -h|--help) + showUsage + exit 0 + ;; + --option) + shift + nixBuildArgs+=("--option" "$1" "$2"); shift + ;; + *) + if [ ! -z "$networkExpr" ]; then + echo "Network expression already set!" + showUsage + exit 1 + fi + networkExpr="$(readlink -f $1)" + ;; esac - + shift done -shift - -# Validate the given options - -if [ "$1" = "" ] +if [ -z "$networkExpr" ] then echo "ERROR: A network expression must be specified!" >&2 exit 1 -else - networkExpr=$(readlink -f $1) fi # Build a network of VMs - nix-build '<nixpkgs/nixos/modules/installer/tools/nixos-build-vms/build-vms.nix>' \ - --argstr networkExpr $networkExpr $noOutLinkArg $showTraceArg + --argstr networkExpr $networkExpr "${nixBuildArgs[@]}" diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 7612dc92dd99..9982cdae9e3d 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -265,6 +265,7 @@ ./services/desktops/pipewire.nix ./services/desktops/gnome3/at-spi2-core.nix ./services/desktops/gnome3/chrome-gnome-shell.nix + ./services/desktops/gnome3/evince.nix ./services/desktops/gnome3/evolution-data-server.nix ./services/desktops/gnome3/file-roller.nix ./services/desktops/gnome3/gnome-disks.nix @@ -748,6 +749,7 @@ ./services/web-apps/icingaweb2/icingaweb2.nix ./services/web-apps/icingaweb2/module-monitoring.nix ./services/web-apps/mattermost.nix + ./services/web-apps/miniflux.nix ./services/web-apps/nextcloud.nix ./services/web-apps/nexus.nix ./services/web-apps/pgpkeyserver-lite.nix diff --git a/nixos/modules/services/audio/ympd.nix b/nixos/modules/services/audio/ympd.nix index d34c1c9d83cc..919b76622510 100644 --- a/nixos/modules/services/audio/ympd.nix +++ b/nixos/modules/services/audio/ympd.nix @@ -15,7 +15,7 @@ in { enable = mkEnableOption "ympd, the MPD Web GUI"; webPort = mkOption { - type = types.string; + type = types.either types.str types.port; # string for backwards compat default = "8080"; description = "The port where ympd's web interface will be available."; example = "ssl://8080:/path/to/ssl-private-key.pem"; @@ -49,7 +49,7 @@ in { systemd.services.ympd = { description = "Standalone MPD Web GUI written in C"; wantedBy = [ "multi-user.target" ]; - serviceConfig.ExecStart = "${pkgs.ympd}/bin/ympd --host ${cfg.mpd.host} --port ${toString cfg.mpd.port} --webport ${cfg.webPort} --user nobody"; + serviceConfig.ExecStart = "${pkgs.ympd}/bin/ympd --host ${cfg.mpd.host} --port ${toString cfg.mpd.port} --webport ${toString cfg.webPort} --user nobody"; }; }; diff --git a/nixos/modules/services/desktops/gnome3/evince.nix b/nixos/modules/services/desktops/gnome3/evince.nix new file mode 100644 index 000000000000..5f040a16f067 --- /dev/null +++ b/nixos/modules/services/desktops/gnome3/evince.nix @@ -0,0 +1,35 @@ +# Evince. + +{ config, pkgs, lib, ... }: + +with lib; + +{ + + ###### interface + + options = { + + services.gnome3.evince = { + + enable = mkEnableOption + "systemd and dbus services for Evince, the GNOME document viewer"; + + }; + + }; + + + ###### implementation + + config = mkIf config.services.gnome3.evince.enable { + + environment.systemPackages = [ pkgs.evince ]; + + services.dbus.packages = [ pkgs.evince ]; + + systemd.packages = [ pkgs.evince ]; + + }; + +} diff --git a/nixos/modules/services/hardware/triggerhappy.nix b/nixos/modules/services/hardware/triggerhappy.nix index 81d4a1ae65bf..bffe7353b10e 100644 --- a/nixos/modules/services/hardware/triggerhappy.nix +++ b/nixos/modules/services/hardware/triggerhappy.nix @@ -57,6 +57,15 @@ in ''; }; + user = mkOption { + type = types.str; + default = "nobody"; + example = "root"; + description = '' + User account under which <command>triggerhappy</command> runs. + ''; + }; + bindings = mkOption { type = types.listOf (types.submodule bindingCfg); default = []; @@ -96,7 +105,7 @@ in after = [ "local-fs.target" ]; description = "Global hotkey daemon"; serviceConfig = { - ExecStart = "${pkgs.triggerhappy}/bin/thd --user nobody --socket ${socket} --triggers ${configFile} --deviceglob /dev/input/event*"; + ExecStart = "${pkgs.triggerhappy}/bin/thd ${optionalString (cfg.user != "root") "--user ${cfg.user}"} --socket ${socket} --triggers ${configFile} --deviceglob /dev/input/event*"; }; }; diff --git a/nixos/modules/services/monitoring/prometheus/default.nix b/nixos/modules/services/monitoring/prometheus/default.nix index 25385be97043..0d73551dc071 100644 --- a/nixos/modules/services/monitoring/prometheus/default.nix +++ b/nixos/modules/services/monitoring/prometheus/default.nix @@ -237,6 +237,14 @@ let Optional http login credentials for metrics scraping. ''; }; + tls_config = mkOption { + type = types.nullOr promTypes.tls_config; + default = null; + apply = x: mapNullable _filter x; + description = '' + Configures the scrape request's TLS settings. + ''; + }; dns_sd_configs = mkOption { type = types.listOf promTypes.dns_sd_config; default = []; @@ -431,6 +439,48 @@ let }; }; + promTypes.tls_config = types.submodule { + options = { + ca_file = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + CA certificate to validate API server certificate with. + ''; + }; + cert_file = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + Certificate file for client cert authentication to the server. + ''; + }; + key_file = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + Key file for client cert authentication to the server. + ''; + }; + server_name = mkOption { + type = types.nullOr types.str; + default = null; + description = '' + ServerName extension to indicate the name of the server. + http://tools.ietf.org/html/rfc4366#section-3.1 + ''; + }; + insecure_skip_verify = mkOption { + type = types.bool; + default = false; + description = '' + Disable validation of the server certificate. + ''; + }; + }; + }; + + in { options = { services.prometheus = { diff --git a/nixos/modules/services/networking/hylafax/default.nix b/nixos/modules/services/networking/hylafax/default.nix index 4c63b822d165..d8ffa3fc04d2 100644 --- a/nixos/modules/services/networking/hylafax/default.nix +++ b/nixos/modules/services/networking/hylafax/default.nix @@ -26,4 +26,6 @@ }]; }; + meta.maintainers = [ lib.maintainers.yarny ]; + } diff --git a/nixos/modules/services/networking/hylafax/faxq-default.nix b/nixos/modules/services/networking/hylafax/faxq-default.nix index a2630ce66b71..9b634650cf79 100644 --- a/nixos/modules/services/networking/hylafax/faxq-default.nix +++ b/nixos/modules/services/networking/hylafax/faxq-default.nix @@ -4,7 +4,7 @@ { - ModemGroup = [ ''"any:.*"'' ]; + ModemGroup = [ ''"any:0:.*"'' ]; ServerTracing = "0x78701"; SessionTracing = "0x78701"; UUCPLockDir = "/var/lock"; diff --git a/nixos/modules/services/networking/networkmanager.nix b/nixos/modules/services/networking/networkmanager.nix index d372dfd8f412..5e5544471818 100644 --- a/nixos/modules/services/networking/networkmanager.nix +++ b/nixos/modules/services/networking/networkmanager.nix @@ -466,7 +466,7 @@ in { systemd.packages = cfg.packages; - systemd.services."network-manager" = { + systemd.services."NetworkManager" = { wantedBy = [ "network.target" ]; restartTriggers = [ configFile ]; @@ -478,9 +478,9 @@ in { }; systemd.services.nm-setup-hostsdirs = mkIf dynamicHostsEnabled { - wantedBy = [ "network-manager.service" ]; - before = [ "network-manager.service" ]; - partOf = [ "network-manager.service" ]; + wantedBy = [ "NetworkManager.service" ]; + before = [ "NetworkManager.service" ]; + partOf = [ "NetworkManager.service" ]; script = concatStrings (mapAttrsToList (n: d: '' mkdir -p "/run/NetworkManager/hostsdirs/${n}" chown "${d.user}:${d.group}" "/run/NetworkManager/hostsdirs/${n}" diff --git a/nixos/modules/services/networking/strongswan.nix b/nixos/modules/services/networking/strongswan.nix index 707d24b9220f..41b69039ba7a 100644 --- a/nixos/modules/services/networking/strongswan.nix +++ b/nixos/modules/services/networking/strongswan.nix @@ -54,7 +54,7 @@ in enable = mkEnableOption "strongSwan"; secrets = mkOption { - type = types.listOf types.path; + type = types.listOf types.str; default = []; example = [ "/run/keys/ipsec-foo.secret" ]; description = '' diff --git a/nixos/modules/services/web-apps/miniflux.nix b/nixos/modules/services/web-apps/miniflux.nix new file mode 100644 index 000000000000..1d60004e574d --- /dev/null +++ b/nixos/modules/services/web-apps/miniflux.nix @@ -0,0 +1,97 @@ +{ config, lib, pkgs, ... }: + +with lib; +let + cfg = config.services.miniflux; + + dbUser = "miniflux"; + dbPassword = "miniflux"; + dbHost = "localhost"; + dbName = "miniflux"; + + defaultCredentials = pkgs.writeText "miniflux-admin-credentials" '' + ADMIN_USERNAME=admin + ADMIN_PASSWORD=password + ''; + + pgsu = "${pkgs.sudo}/bin/sudo -u ${config.services.postgresql.superUser}"; + pgbin = "${config.services.postgresql.package}/bin"; + preStart = pkgs.writeScript "miniflux-pre-start" '' + #!${pkgs.runtimeShell} + db_exists() { + [ "$(${pgsu} ${pgbin}/psql -Atc "select 1 from pg_database where datname='$1'")" == "1" ] + } + if ! db_exists "${dbName}"; then + ${pgsu} ${pgbin}/psql postgres -c "CREATE ROLE ${dbUser} WITH LOGIN NOCREATEDB NOCREATEROLE ENCRYPTED PASSWORD '${dbPassword}'" + ${pgsu} ${pgbin}/createdb --owner "${dbUser}" "${dbName}" + ${pgsu} ${pgbin}/psql "${dbName}" -c "CREATE EXTENSION IF NOT EXISTS hstore" + fi + ''; +in + +{ + options = { + services.miniflux = { + enable = mkEnableOption "miniflux"; + + config = mkOption { + type = types.attrsOf types.str; + example = literalExample '' + { + CLEANUP_FREQUENCY = "48"; + LISTEN_ADDR = "localhost:8080"; + } + ''; + description = '' + Configuration for Miniflux, refer to + <link xlink:href="http://docs.miniflux.app/en/latest/configuration.html"/> + for documentation on the supported values. + ''; + }; + + adminCredentialsFile = mkOption { + type = types.nullOr types.path; + default = null; + description = '' + File containing the ADMIN_USERNAME, default is "admin", and + ADMIN_PASSWORD (length >= 6), default is "password"; in the format of + an EnvironmentFile=, as described by systemd.exec(5). + ''; + example = "/etc/nixos/miniflux-admin-credentials"; + }; + }; + }; + + config = mkIf cfg.enable { + + services.miniflux.config = { + LISTEN_ADDR = mkDefault "localhost:8080"; + DATABASE_URL = "postgresql://${dbUser}:${dbPassword}@${dbHost}/${dbName}?sslmode=disable"; + RUN_MIGRATIONS = "1"; + CREATE_ADMIN = "1"; + }; + + services.postgresql.enable = true; + + systemd.services.miniflux = { + description = "Miniflux service"; + wantedBy = [ "multi-user.target" ]; + requires = [ "postgresql.service" ]; + after = [ "network.target" "postgresql.service" ]; + + serviceConfig = { + ExecStart = "${pkgs.miniflux}/bin/miniflux"; + ExecStartPre = "+${preStart}"; + DynamicUser = true; + RuntimeDirectory = "miniflux"; + RuntimeDirectoryMode = "0700"; + EnvironmentFile = if isNull cfg.adminCredentialsFile + then defaultCredentials + else cfg.adminCredentialsFile; + }; + + environment = cfg.config; + }; + environment.systemPackages = [ pkgs.miniflux ]; + }; +} diff --git a/nixos/modules/services/x11/desktop-managers/gnome3.nix b/nixos/modules/services/x11/desktop-managers/gnome3.nix index ea01749349de..121ef07c00dd 100644 --- a/nixos/modules/services/x11/desktop-managers/gnome3.nix +++ b/nixos/modules/services/x11/desktop-managers/gnome3.nix @@ -126,6 +126,7 @@ in { services.dleyna-renderer.enable = mkDefault true; services.dleyna-server.enable = mkDefault true; services.gnome3.at-spi2-core.enable = true; + services.gnome3.evince.enable = mkDefault true; services.gnome3.evolution-data-server.enable = true; services.gnome3.file-roller.enable = mkDefault true; services.gnome3.gnome-disks.enable = mkDefault true; @@ -160,7 +161,11 @@ in { # If gnome3 is installed, build vim for gtk3 too. nixpkgs.config.vim.gui = "gtk3"; - fonts.fonts = [ pkgs.dejavu_fonts pkgs.cantarell-fonts ]; + fonts.fonts = [ + pkgs.dejavu_fonts pkgs.cantarell-fonts + pkgs.source-sans-pro + pkgs.source-code-pro # Default monospace font in 3.32 + ]; services.xserver.displayManager.extraSessionFilePackages = [ pkgs.gnome3.gnome-session ] ++ map diff --git a/nixos/modules/services/x11/desktop-managers/pantheon.nix b/nixos/modules/services/x11/desktop-managers/pantheon.nix index e81aea68ae98..a27e75532be9 100644 --- a/nixos/modules/services/x11/desktop-managers/pantheon.nix +++ b/nixos/modules/services/x11/desktop-managers/pantheon.nix @@ -122,6 +122,7 @@ in # pantheon has pantheon-agent-geoclue2 services.geoclue2.enableDemoAgent = false; services.gnome3.at-spi2-core.enable = true; + services.gnome3.evince.enable = mkDefault true; services.gnome3.evolution-data-server.enable = true; services.gnome3.file-roller.enable = mkDefault true; # TODO: gnome-keyring's xdg autostarts will still be in the environment (from elementary-session-settings) if disabled forcefully @@ -168,7 +169,6 @@ in gnome3.geary gnome3.epiphany gnome3.gnome-font-viewer - evince ] ++ pantheon.apps) config.environment.pantheon.excludePackages) ++ (with pkgs; [ diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index 14d855f44dc7..8b27ff808e6b 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -138,6 +138,7 @@ in matrix-synapse = handleTest ./matrix-synapse.nix {}; memcached = handleTest ./memcached.nix {}; mesos = handleTest ./mesos.nix {}; + miniflux = handleTest ./miniflux.nix {}; minio = handleTest ./minio.nix {}; misc = handleTest ./misc.nix {}; mongodb = handleTest ./mongodb.nix {}; diff --git a/nixos/tests/miniflux.nix b/nixos/tests/miniflux.nix new file mode 100644 index 000000000000..19ab4803a1d3 --- /dev/null +++ b/nixos/tests/miniflux.nix @@ -0,0 +1,52 @@ +import ./make-test.nix ({ pkgs, lib, ... }: + +let + port = 3142; + username = "alice"; + password = "correcthorsebatterystaple"; + defaultPort = 8080; + defaultUsername = "admin"; + defaultPassword = "password"; +in +with lib; +{ + name = "miniflux"; + meta.maintainers = with pkgs.stdenv.lib.maintainers; [ bricewge ]; + + nodes = { + default = + { ... }: + { + services.miniflux.enable = true; + }; + + customized = + { ... }: + { + services.miniflux = { + enable = true; + config = { + CLEANUP_FREQUENCY = "48"; + LISTEN_ADDR = "localhost:${toString port}"; + }; + adminCredentialsFile = pkgs.writeText "admin-credentials" '' + ADMIN_USERNAME=${username} + ADMIN_PASSWORD=${password} + ''; + }; + }; + }; + testScript = '' + startAll; + + $default->waitForUnit('miniflux.service'); + $default->waitForOpenPort(${toString defaultPort}); + $default->succeed("curl --fail 'http://localhost:${toString defaultPort}/healthcheck' | grep -q OK"); + $default->succeed("curl 'http://localhost:${toString defaultPort}/v1/me' -u '${defaultUsername}:${defaultPassword}' -H Content-Type:application/json | grep -q '\"is_admin\":true'"); + + $customized->waitForUnit('miniflux.service'); + $customized->waitForOpenPort(${toString port}); + $customized->succeed("curl --fail 'http://localhost:${toString port}/healthcheck' | grep -q OK"); + $customized->succeed("curl 'http://localhost:${toString port}/v1/me' -u '${username}:${password}' -H Content-Type:application/json | grep -q '\"is_admin\":true'"); + ''; +}) |