diff options
author | James ‘Twey’ Kay <twey@twey.co.uk> | 2020-09-06 04:04:19 +0100 |
---|---|---|
committer | James ‘Twey’ Kay <twey@twey.co.uk> | 2020-09-06 04:04:19 +0100 |
commit | a9def8ddbc71033476fe68c358d81524b820d7f0 (patch) | |
tree | e0eefcb4c7eb97da1be5a1bb1c46b386b5a471d7 /pkgs/servers/rainloop | |
parent | c914fffeba8b9e3d89e8a370c44fc32062c27fc1 (diff) |
rainloop: allow multiple instances to use the same package
Diffstat (limited to 'pkgs/servers/rainloop')
-rw-r--r-- | pkgs/servers/rainloop/default.nix | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/pkgs/servers/rainloop/default.nix b/pkgs/servers/rainloop/default.nix index bff5d2ea30629..42c68d5608edb 100644 --- a/pkgs/servers/rainloop/default.nix +++ b/pkgs/servers/rainloop/default.nix @@ -24,7 +24,8 @@ */ function __get_custom_data_full_path() { - return '${dataPath}'; // custom data folder path + $v = getenv('RAINLOOP_DATA_DIR', TRUE); + return $v === FALSE ? '${dataPath}' : $v; } ''; @@ -33,6 +34,8 @@ cp -r rainloop/* $out rm -rf $out/data cp ${includeScript} $out/include.php + mkdir $out/data + chmod 700 $out/data ''; meta = with stdenv.lib; { @@ -44,13 +47,13 @@ maintainers = with maintainers; [ das_j ]; }; }); - in { - rainloop-community = common { - edition = "community"; - sha256 = "0a8qafm4khwj8cnaiaxvjb9073w6fr63vk1b89nks4hmfv10jn6y"; - }; - rainloop-standard = common { - edition = ""; - sha256 = "0961g4mci080f7y98zx9r4qw620l4z3na1ivvlyhhr1v4dywqvch"; - }; - } +in { + rainloop-community = common { + edition = "community"; + sha256 = "0a8qafm4khwj8cnaiaxvjb9073w6fr63vk1b89nks4hmfv10jn6y"; + }; + rainloop-standard = common { + edition = ""; + sha256 = "0961g4mci080f7y98zx9r4qw620l4z3na1ivvlyhhr1v4dywqvch"; + }; +} |