Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 2a842a1386b8
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 38b2520b96d2
Choose a head ref
  • 2 commits
  • 2 files changed
  • 2 contributors

Commits on Nov 1, 2018

  1. bacula: 5.2.13 -> 9.2.1

    proteansec committed Nov 1, 2018
    Copy the full SHA
    02a3726 View commit details

Commits on Nov 10, 2018

  1. Merge pull request #37365 from proteansec/pkgs/bacula

    bacula: 5.2.13 -> 9.2.1
    infinisil authored Nov 10, 2018
    Copy the full SHA
    38b2520 View commit details
Showing with 30 additions and 10 deletions.
  1. +18 −6 nixos/modules/services/backup/bacula.nix
  2. +12 −4 pkgs/tools/backup/bacula/default.nix
24 changes: 18 additions & 6 deletions nixos/modules/services/backup/bacula.nix
Original file line number Diff line number Diff line change
@@ -346,17 +346,25 @@ in {
description = "Bacula File Daemon";
wantedBy = [ "multi-user.target" ];
path = [ pkgs.bacula ];
serviceConfig.ExecStart = "${pkgs.bacula}/sbin/bacula-fd -f -u root -g bacula -c ${fd_conf}";
serviceConfig.ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
serviceConfig = {
ExecStart = "${pkgs.bacula}/sbin/bacula-fd -f -u root -g bacula -c ${fd_conf}";
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
LogsDirectory = "bacula";
StateDirectory = "bacula";
};
};

systemd.services.bacula-sd = mkIf sd_cfg.enable {
after = [ "network.target" ];
description = "Bacula Storage Daemon";
wantedBy = [ "multi-user.target" ];
path = [ pkgs.bacula ];
serviceConfig.ExecStart = "${pkgs.bacula}/sbin/bacula-sd -f -u bacula -g bacula -c ${sd_conf}";
serviceConfig.ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
serviceConfig = {
ExecStart = "${pkgs.bacula}/sbin/bacula-sd -f -u bacula -g bacula -c ${sd_conf}";
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
LogsDirectory = "bacula";
StateDirectory = "bacula";
};
};

services.postgresql.enable = dir_cfg.enable == true;
@@ -366,8 +374,12 @@ in {
description = "Bacula Director Daemon";
wantedBy = [ "multi-user.target" ];
path = [ pkgs.bacula ];
serviceConfig.ExecStart = "${pkgs.bacula}/sbin/bacula-dir -f -u bacula -g bacula -c ${dir_conf}";
serviceConfig.ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
serviceConfig = {
ExecStart = "${pkgs.bacula}/sbin/bacula-dir -f -u bacula -g bacula -c ${dir_conf}";
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
LogsDirectory = "bacula";
StateDirectory = "bacula";
};
preStart = ''
if ! test -e "${libDir}/db-created"; then
${pkgs.postgresql}/bin/createuser --no-superuser --no-createdb --no-createrole bacula
16 changes: 12 additions & 4 deletions pkgs/tools/backup/bacula/default.nix
Original file line number Diff line number Diff line change
@@ -1,20 +1,28 @@
{ stdenv, fetchurl, sqlite, postgresql, zlib, acl, ncurses, openssl, readline }:

stdenv.mkDerivation rec {
name = "bacula-5.2.13";
name = "bacula-9.2.1";

src = fetchurl {
url = "mirror://sourceforge/bacula/${name}.tar.gz";
sha256 = "1n3sc0kd7r0afpyi708y3md0a24rbldnfcdz0syqj600pxcd9gm4";
sha256 = "1mv6axdlv246yww9g2ra76hir1km36cv8lk2gal8kv71i64vafmf";
};

buildInputs = [ postgresql sqlite zlib ncurses openssl readline ]
# acl relies on attr, which I can't get to build on darwin
++ stdenv.lib.optional (!stdenv.isDarwin) acl;

configureFlags = [
configureFlags = [
"--with-sqlite3=${sqlite.dev}"
"--with-postgresql=${postgresql}"
"--with-logdir=/var/log/bacula"
"--with-working-dir=/var/lib/bacula"
"--mandir=\${out}/share/man"
];

installFlags = [
"logdir=\${out}/logdir"
"working_dir=\${out}/workdir"
];

postInstall = ''
@@ -26,7 +34,7 @@ stdenv.mkDerivation rec {
description = "Enterprise ready, Network Backup Tool";
homepage = http://bacula.org/;
license = licenses.gpl2;
maintainers = with maintainers; [ domenkozar lovek323 ];
maintainers = with maintainers; [ domenkozar lovek323 eleanor ];
platforms = platforms.all;
};
}