Skip to content

Commit c06efc8

Browse files
erictapenSuperSandro2000
authored andcommitted
nixos/mastodon: some formatting
1 parent 60d2878 commit c06efc8

File tree

1 file changed

+18
-16
lines changed

1 file changed

+18
-16
lines changed

nixos/modules/services/web-apps/mastodon.nix

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ in {
195195
affect other virtualHosts running on your nginx instance, if any.
196196
Alternatively you can configure a reverse-proxy of your choice to serve these paths:
197197
198-
`/ -> $(nix-instantiate --eval '<nixpkgs>' -A mastodon.outPath)/public`
198+
`/ -> ''${pkgs.mastodon}/public`
199199
200200
`/ -> 127.0.0.1:{{ webPort }} `(If there was no file in the directory above.)
201201
@@ -324,6 +324,21 @@ in {
324324
type = lib.types.str;
325325
};
326326

327+
vapidPrivateKeyFile = lib.mkOption {
328+
description = ''
329+
Path to file containing the private key used for Web Push
330+
Voluntary Application Server Identification. A new keypair can
331+
be generated by running:
332+
333+
`nix build -f '<nixpkgs>' mastodon; cd result; bin/rake webpush:generate_keys`
334+
335+
If this file does not exist, it will be created with a new
336+
private key.
337+
'';
338+
default = "/var/lib/mastodon/secrets/vapid-private-key";
339+
type = lib.types.str;
340+
};
341+
327342
localDomain = lib.mkOption {
328343
description = "The domain serving your Mastodon instance.";
329344
example = "social.example.org";
@@ -401,21 +416,6 @@ in {
401416
type = lib.types.str;
402417
};
403418

404-
vapidPrivateKeyFile = lib.mkOption {
405-
description = ''
406-
Path to file containing the private key used for Web Push
407-
Voluntary Application Server Identification. A new keypair can
408-
be generated by running:
409-
410-
`nix build -f '<nixpkgs>' mastodon; cd result; bin/rake webpush:generate_keys`
411-
412-
If this file does not exist, it will be created with a new
413-
private key.
414-
'';
415-
default = "/var/lib/mastodon/secrets/vapid-private-key";
416-
type = lib.types.str;
417-
};
418-
419419
trustedProxy = lib.mkOption {
420420
description = ''
421421
You need to set it to the IP from which your reverse proxy sends requests to Mastodon's web process,
@@ -945,6 +945,7 @@ in {
945945
enable = true;
946946
hostname = lib.mkDefault "${cfg.localDomain}";
947947
};
948+
948949
services.redis.servers.mastodon = lib.mkIf redisActuallyCreateLocally (lib.mkMerge [
949950
{
950951
enable = true;
@@ -953,6 +954,7 @@ in {
953954
port = cfg.redis.port;
954955
})
955956
]);
957+
956958
services.postgresql = lib.mkIf databaseActuallyCreateLocally {
957959
enable = true;
958960
ensureUsers = [

0 commit comments

Comments
 (0)