aboutsummaryrefslogtreecommitdiff
path: root/modules/pkgs/rdsdump/default.nix
blob: 5d9b0249dbd02dfcafedd18624129a46346a00c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
{ stdenv, bash, mysql, makeWrapper }:

stdenv.mkDerivation {
  name = "rdsdump";
  buildInputs = [ bash ];
  phases = [ "installPhase" ];
  nativeBuildInputs = [ makeWrapper ];
  installPhase = ''
    mkdir -p $out/bin
    cp -a ${./rdsdump.bash} $out/bin/rdsdump
    chmod +x $out/bin/rdsdump
    patchShebangs $out/bin/rdsdump
    wrapProgram "$out/bin/rdsdump" \
      --prefix PATH : '${mysql.client.bin}/bin'
  '';
}