mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-14 21:49:34 +03:00
Merge pull request #224549 from mweinelt/go-neb-unit-permissions
nixos/go-neb: Replace PermissionsStartOnly with executable prefix
This commit is contained in:
commit
130be87c8d
1 changed files with 1 additions and 2 deletions
|
@ -60,13 +60,12 @@ in {
|
||||||
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
ExecStartPre = lib.optional (cfg.secretFile != null)
|
ExecStartPre = lib.optional (cfg.secretFile != null)
|
||||||
(pkgs.writeShellScript "pre-start" ''
|
("+" + pkgs.writeShellScript "pre-start" ''
|
||||||
umask 077
|
umask 077
|
||||||
export $(xargs < ${cfg.secretFile})
|
export $(xargs < ${cfg.secretFile})
|
||||||
${pkgs.envsubst}/bin/envsubst -i "${configFile}" > ${finalConfigFile}
|
${pkgs.envsubst}/bin/envsubst -i "${configFile}" > ${finalConfigFile}
|
||||||
chown go-neb ${finalConfigFile}
|
chown go-neb ${finalConfigFile}
|
||||||
'');
|
'');
|
||||||
PermissionsStartOnly = true;
|
|
||||||
RuntimeDirectory = "go-neb";
|
RuntimeDirectory = "go-neb";
|
||||||
ExecStart = "${pkgs.go-neb}/bin/go-neb";
|
ExecStart = "${pkgs.go-neb}/bin/go-neb";
|
||||||
User = "go-neb";
|
User = "go-neb";
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue