diff options
author | Mynacol <Mynacol@users.noreply.github.com> | 2024-04-19 00:06:59 +0200 |
---|---|---|
committer | Mynacol <Mynacol@users.noreply.github.com> | 2024-04-19 00:06:59 +0200 |
commit | 774cd77f2b7952f5ba75933f980212923462e1ef (patch) | |
tree | adf3907d2f135a38d67d3a471df7f750befc5dfc /nixos/modules/services/web-apps | |
parent | f2b40d13cc4efac70db5ae4c099018dd19a30595 (diff) |
nixos/akkoma: Fix media proxy URLs after upgrade
The upgrade of akkoma to 3.12.1 required to specify media upload and
media proxy URLs by default. The default value for media proxy was
wrong, leading to broken `example.com/media/proxy/[...]` URLs.
As descried in the [upgrade guide](https://meta.akkoma.dev/t/akkoma-stable-2024-03-securer-i-barely-know-her/681#explicit-upload-and-media-proxy-domains-5),
the media proxy `base_url` should be set to `https://example.com`
(without a path component). The suffix already contains `proxy/[...]`,
which gives the expected URLs.
Diffstat (limited to 'nixos/modules/services/web-apps')
-rw-r--r-- | nixos/modules/services/web-apps/akkoma.nix | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nixos/modules/services/web-apps/akkoma.nix b/nixos/modules/services/web-apps/akkoma.nix index eca498549df3..b180db2d4ca0 100644 --- a/nixos/modules/services/web-apps/akkoma.nix +++ b/nixos/modules/services/web-apps/akkoma.nix @@ -817,11 +817,11 @@ in { base_url = mkOption { type = types.nullOr types.nonEmptyStr; default = if lib.versionOlder config.system.stateVersion "24.05" - then "${httpConf.scheme}://${httpConf.host}:${builtins.toString httpConf.port}/media/" + then "${httpConf.scheme}://${httpConf.host}:${builtins.toString httpConf.port}" else null; defaultText = literalExpression '' if lib.versionOlder config.system.stateVersion "24.05" - then "$\{httpConf.scheme}://$\{httpConf.host}:$\{builtins.toString httpConf.port}/media/" + then "$\{httpConf.scheme}://$\{httpConf.host}:$\{builtins.toString httpConf.port}" else null; ''; description = '' |