longview service: don't write passwords to nix store

Adds services.longview.{apiKeyFile,mysqlPasswordFile} options as
alternatives to apiKey and mysqlPassword, which still work, but are
deprecated with a warning message.

Related to #24288.
This commit is contained in:
Rodney Lorrimar
2017-03-26 23:06:42 +01:00
parent eab30996bd
commit db14ea3926
2 changed files with 82 additions and 35 deletions
+6 -1
View File
@@ -16,8 +16,13 @@ stdenv.mkDerivation rec {
./log-stdout.patch
];
# Read all configuration from /run/longview
postPatch = ''
substituteInPlace Linode/Longview/Util.pm --replace /var/run/longview.pid /run/longview.pid
substituteInPlace Linode/Longview/Util.pm \
--replace /var/run/longview.pid /run/longview/longview.pid \
--replace /etc/linode /run/longview
substituteInPlace Linode/Longview.pl \
--replace /etc/linode /run/longview
'';
buildInputs = [ perl makeWrapper glibc ]