+1
-3
nixos/doc/manual/redirects.json
+1
-3
nixos/doc/manual/redirects.json
···
+6
-4
nixos/modules/services/search/meilisearch.md
+6
-4
nixos/modules/services/search/meilisearch.md
···- The default nixos package doesn't come with the [dashboard](https://docs.meilisearch.com/learn/getting_started/quick_start.html#search), since the dashboard features makes some assets downloads at compile time.-- Default deployment is development mode. It doesn't require a secret master key. All routes are not protected and accessible.+- `http_addr` is derived from {option}`services.meilisearch.listenAddress` and {option}`services.meilisearch.listenPort`. The two sub-fields are separate because this makes it easier to consume in certain other modules.+- `db_path` is set to `/var/lib/meilisearch` by default. Upstream, the default value is equivalent to `/var/lib/meilisearch/data.ms`.+- `dump_dir` and `snapshot_dir` are set to `/var/lib/meilisearch/dumps` and `/var/lib/meilisearch/snapshots`, respectively. This is equivalent to the upstream defaults.-- the snapshot feature is not yet configurable from the module, it's just a matter of adding the relevant environment variables.+- All other options inherit their upstream defaults. In particular, the default configuration uses `env = "development"`, which doesn't require a master key, in which case all routes are unprotected.
+160
-90
nixos/modules/services/search/meilisearch.nix
+160
-90
nixos/modules/services/search/meilisearch.nix
···+Use `services.meilisearch.masterKeyFile` instead. It does not require you to prefix the file with "MEILI_MASTER_KEY=".+If you were abusing this option to set other options, you can now configure them with `services.meilisearch.settings`.···+It can also be a hostname like "localhost". If it resolves to an IPv4 and IPv6 address, Meilisearch will listen on both.-- 'DEBUG': log all events and including detailed information on MeiliSearch's internal processes.+https://www.meilisearch.com/docs/learn/self_hosted/configure_meilisearch_at_launch#all-instance-options-More information at https://www.meilisearch.com/docs/learn/update_and_migration/updating#dumpless-upgrade+# we do this because some dependent services like Misskey/Sharkey need separate host,port for no good reason.+# upstream's default for `db_path` is `/var/lib/meilisearch/data.ms/`, but ours is different for no reason.···+${lib.getExe pkgs.replace-secret} '${master-key-placeholder}' "$CREDENTIALS_DIRECTORY/master_key" "$RUNTIME_DIRECTORY/config.toml"-EnvironmentFile = lib.mkIf (cfg.masterKeyEnvironmentFile != null) cfg.masterKeyEnvironmentFile;
+2
-2
nixos/modules/services/web-apps/sharkey.nix
+2
-2
nixos/modules/services/web-apps/sharkey.nix
···-You need to ensure `services.meilisearch.masterKeyEnvironmentFile` is correctly configured for a workingMeilisearch setup. You also need to configure Sharkey to use an API key obtained from Meilisearch with the`MK_CONFIG_MEILISEARCH_APIKEY` environment variable, and set `services.sharkey.settings.meilisearch.index` tothe created index. See https://docs.joinsharkey.org/docs/customisation/search/meilisearch/ for how to create···
+11
-12
nixos/tests/meilisearch.nix
+11
-12
nixos/tests/meilisearch.nix
···+f"curl ${apiUrl}/tasks/{task_uid} | jq -e '.status | IN(\"succeeded\", \"failed\", \"canceled\")'"+wait_task("curl -X POST -H 'Content-Type: application/json' ${apiUrl}/indexes --data @${indexJSON}")-"curl -X POST -H 'Content-Type: application/json' ${apiUrl}/indexes/${uid}/documents --data-binary @${moviesJSON}"+wait_task("curl -X POST -H 'Content-Type: application/json' ${apiUrl}/indexes/${uid}/documents --data-binary @${moviesJSON}")
+1
-3
nixos/tests/web-apps/sharkey.nix
+1
-3
nixos/tests/web-apps/sharkey.nix