summaryrefslogtreecommitdiffstats
path: root/krebs/5pkgs/simple/krebszones/default.nix
blob: 32608e7fab030258d917a6206a1380d2d2971eb0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
{ pkgs, ... }:

pkgs.writeDashBin "krebszones" ''
  set -efu
  export OVH_ZONE_CONFIG=''${OVH_ZONE_CONFIG:-$HOME/.secrets/krebs/ovh-zone.conf}
  case $* in
    import)
      set -- import /etc/zones/krebsco.de krebsco.de
      echo "+ krebszones $*" >&2
      ;;
  esac
  exec ${pkgs.ovh-zone}/bin/ovh-zone "$@"
''