Nextcloud: Difference between revisions
→Configuration: Modernize fetchNextcloudApp usage |
m Update 'mc' command |
||
(4 intermediate revisions by 3 users not shown) | |||
Line 24: | Line 24: | ||
=== Apps === | === Apps === | ||
[https://github.com/NixOS/nixpkgs/blob/ | [https://github.com/NixOS/nixpkgs/blob/2852f35f477e0f55e68b5f5e6d5a92242c215efc/pkgs/servers/nextcloud/packages/31.json Some apps] (use the file named <code><version>.json</code>, where version is the installed Nextcloud version), which are already packaged on NixOS, can be installed directly with the following example configuration: | ||
{{file|/etc/nixos/configuration.nix|nix|<nowiki> | {{file|/etc/nixos/configuration.nix|nix|<nowiki> | ||
Line 176: | Line 176: | ||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
mc | mc alias set minio http://localhost:9000 ${accessKey} ${secretKey} --api s3v4 | ||
mc mb minio/nextcloud | mc mb minio/nextcloud | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Line 206: | Line 206: | ||
=== Secrets management === | === Secrets management === | ||
Do not suply passwords, hashes or keys via | Do not suply passwords, hashes or keys via the settings option, since they will be copied into the world-readable Nix store. Instead reference a JSON file containing secrets using the <code>secretFile</code> option. | ||
<syntaxHighlight lang="nix"> | <syntaxHighlight lang="nix"> | ||
Line 325: | Line 325: | ||
{{file|/etc/nixos/configuration.nix|nix|<nowiki> | {{file|/etc/nixos/configuration.nix|nix|<nowiki> | ||
services.nginx.virtualHosts." | services.nginx.virtualHosts."${config.services.nextcloud.hostName}".listen = [ { addr = "127.0.0.1"; port = 8080; } ]; | ||
</nowiki>}} | </nowiki>}} | ||
=== Enable HEIC image preview === | === Enable HEIC image preview === | ||
HEIC image preview needs to be explicitly enabled. This is done by adjusting the <code>enabledPreviewProviders</code> option. Beside the default list of supported formats, add an additional line <code>"OC\\Preview\\HEIC"</code> for HEIC image support. | HEIC image preview needs to be explicitly enabled. This is done by adjusting the <code>enabledPreviewProviders</code> option. Beside the default list of supported formats, add an additional line <code>"OC\\Preview\\HEIC"</code> for HEIC image support. See also [https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/config_sample_php_parameters.html#enabledpreviewproviders this list of preview providers] for additional file types. | ||
{{file|/etc/nixos/configuration.nix|nix|<nowiki> | {{file|/etc/nixos/configuration.nix|nix|<nowiki> |