aboutsummaryrefslogtreecommitdiff
path: root/nixops/modules/websites/tools/mastodon/mastodon.nix
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2019-01-28 00:46:11 +0100
committerIsmaël Bouya <ismael.bouya@normalesup.org>2019-01-28 00:46:11 +0100
commit591ebd877b8d5465da95fd7e212da5ef747944ca (patch)
tree777a1c08ed67de2f0b132ca16998a6297627a7a2 /nixops/modules/websites/tools/mastodon/mastodon.nix
parentc9af72bccc8324af25dde5704867fad0f56418bb (diff)
downloadNix-591ebd877b8d5465da95fd7e212da5ef747944ca.tar.gz
Nix-591ebd877b8d5465da95fd7e212da5ef747944ca.tar.zst
Nix-591ebd877b8d5465da95fd7e212da5ef747944ca.zip
Configure mailer spool for tools
Fixes https://git.immae.eu/mantisbt/view.php?id=104
Diffstat (limited to 'nixops/modules/websites/tools/mastodon/mastodon.nix')
-rw-r--r--nixops/modules/websites/tools/mastodon/mastodon.nix7
1 files changed, 4 insertions, 3 deletions
diff --git a/nixops/modules/websites/tools/mastodon/mastodon.nix b/nixops/modules/websites/tools/mastodon/mastodon.nix
index 770aa2c..8650ee3 100644
--- a/nixops/modules/websites/tools/mastodon/mastodon.nix
+++ b/nixops/modules/websites/tools/mastodon/mastodon.nix
@@ -84,10 +84,9 @@ let
84 VAPID_PRIVATE_KEY=${env.vapid.private} 84 VAPID_PRIVATE_KEY=${env.vapid.private}
85 VAPID_PUBLIC_KEY=${env.vapid.public} 85 VAPID_PUBLIC_KEY=${env.vapid.public}
86 86
87 SMTP_SERVER=mail.immae.eu 87 SMTP_DELIVERY_METHOD=sendmail
88 SMTP_PORT=587
89 SMTP_FROM_ADDRESS=notifications@mastodon.immae.eu 88 SMTP_FROM_ADDRESS=notifications@mastodon.immae.eu
90 SMTP_DELIVERY_METHOD=smtp 89 SENDMAIL_LOCATION="/run/wrappers/bin/sendmail"
91 PAPERCLIP_ROOT_PATH=${varDir} 90 PAPERCLIP_ROOT_PATH=${varDir}
92 91
93 STREAMING_CLUSTER_NUM=1 92 STREAMING_CLUSTER_NUM=1
@@ -115,6 +114,8 @@ let
115 cp -a $mastodon $out 114 cp -a $mastodon $out
116 cd $out 115 cd $out
117 chmod u+rwX . public 116 chmod u+rwX . public
117 chmod -R u+rwX config/
118 sed -i -e 's@^end$@ config.action_mailer.sendmail_settings = { location: ENV.fetch("SENDMAIL_LOCATION", "/usr/sbin/sendmail") }\nend@' config/environments/production.rb
118 RAILS_ENV=production ${gems}/bin/rails assets:precompile 119 RAILS_ENV=production ${gems}/bin/rails assets:precompile
119 rm -rf tmp/cache 120 rm -rf tmp/cache
120 ln -sf ../../../../../../../${varDir}/tmp/cache tmp 121 ln -sf ../../../../../../../${varDir}/tmp/cache tmp