dovwiefiwuef'
This commit is contained in:
@@ -1,6 +1,5 @@
|
|||||||
{
|
{
|
||||||
# TODO: check whether there is no TODOs
|
# TODO: check whether there is no TODOs
|
||||||
# TODO: check whether there is no hedgegdoc mentions
|
|
||||||
description = "Mastodon module";
|
description = "Mastodon module";
|
||||||
|
|
||||||
outputs = { ... }:
|
outputs = { ... }:
|
||||||
|
@@ -114,7 +114,7 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
selfprivacy.emails."noreply.mastodon" = {
|
selfprivacy.emails."noreplymastodon" = {
|
||||||
hashedPasswordFile = secrets.hashedPasswordFile;
|
hashedPasswordFile = secrets.hashedPasswordFile;
|
||||||
systemdTargets = [ "mastodon-email-password-setup.service" ];
|
systemdTargets = [ "mastodon-email-password-setup.service" ];
|
||||||
sendOnly = true;
|
sendOnly = true;
|
||||||
@@ -125,6 +125,7 @@ in
|
|||||||
enable = true;
|
enable = true;
|
||||||
wantedBy = [ "multi-user.target" "mastodon-web.service" "postfix.service" ];
|
wantedBy = [ "multi-user.target" "mastodon-web.service" "postfix.service" ];
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
|
Slice = "mastodon.slice";
|
||||||
Type = "oneshot";
|
Type = "oneshot";
|
||||||
ExecStart = pkgs.writeShellScript "gen-mastodon-email-password" ''
|
ExecStart = pkgs.writeShellScript "gen-mastodon-email-password" ''
|
||||||
export password=$(head -c 32 /dev/urandom | base64 | sed 's/[+=\\/A-Z]//g')
|
export password=$(head -c 32 /dev/urandom | base64 | sed 's/[+=\\/A-Z]//g')
|
||||||
@@ -184,7 +185,7 @@ in
|
|||||||
services.mastodon-web = {
|
services.mastodon-web = {
|
||||||
unitConfig.RequiresMountsFor = lib.mkIf sp.useBinds "/volumes/${cfg.location}/mastodon";
|
unitConfig.RequiresMountsFor = lib.mkIf sp.useBinds "/volumes/${cfg.location}/mastodon";
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
Slice = "hedgedoc.slice";
|
Slice = "mastodon.slice";
|
||||||
LoadCredential = ["client-secret:${oauthClientSecretFP}"];
|
LoadCredential = ["client-secret:${oauthClientSecretFP}"];
|
||||||
ExecStart = lib.mkForce (pkgs.writeShellScript "run-mastodon-with-client-secret" ''
|
ExecStart = lib.mkForce (pkgs.writeShellScript "run-mastodon-with-client-secret" ''
|
||||||
export OIDC_CLIENT_SECRET=$(cat $CREDENTIALS_DIRECTORY/client-secret)
|
export OIDC_CLIENT_SECRET=$(cat $CREDENTIALS_DIRECTORY/client-secret)
|
||||||
|
Reference in New Issue
Block a user