From f6c77b183fc8938f9482c67f98cd7f5d7500204c Mon Sep 17 00:00:00 2001 From: "M. A" Date: Fri, 8 Jul 2022 20:28:33 +0000 Subject: [PATCH] snipe-it: Substitute path to mysqldump Snipe-IT has an internal command for backup creation (i.e. `snipe-it snipeit:backup`) which relies on a hardcoded path to the `mysqldump` binary. --- pkgs/servers/web-apps/snipe-it/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/servers/web-apps/snipe-it/default.nix b/pkgs/servers/web-apps/snipe-it/default.nix index 02a1ff30d8f9..102db33117bb 100644 --- a/pkgs/servers/web-apps/snipe-it/default.nix +++ b/pkgs/servers/web-apps/snipe-it/default.nix @@ -1,4 +1,4 @@ -{ pkgs, stdenv, lib, fetchFromGitHub, dataDir ? "/var/lib/snipe-it" }: +{ pkgs, stdenv, lib, fetchFromGitHub, dataDir ? "/var/lib/snipe-it", mariadb }: let package = (import ./composition.nix { @@ -13,6 +13,7 @@ let ln -s ${dataDir}/public/uploads $out/public/uploads ln -s ${dataDir}/bootstrap/cache $out/bootstrap/cache chmod +x $out/artisan + substituteInPlace config/database.php --replace "env('DB_DUMP_PATH', '/usr/local/bin')" "env('DB_DUMP_PATH', '${mariadb}/bin')" ''; });