From 030d0727c85752ea4beea691a47c581bcb145c2b Mon Sep 17 00:00:00 2001 From: Robin Stumm Date: Mon, 16 Jan 2023 15:35:03 +0100 Subject: [PATCH] cicero nomad job: add substituter for exec driver to transformer and remove config for nix driver (no longer used) --- nix/cloud/nomadEnvs/cicero/default.nix | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/nix/cloud/nomadEnvs/cicero/default.nix b/nix/cloud/nomadEnvs/cicero/default.nix index 94422c9..1318f10 100644 --- a/nix/cloud/nomadEnvs/cicero/default.nix +++ b/nix/cloud/nomadEnvs/cicero/default.nix @@ -72,14 +72,9 @@ if .Type != null and .Type != "batch" then . else ( .TaskGroups[]?.Tasks[]? |= ( .Vault.Policies += ["cicero"] | - if .Driver != "nix" or .Config?.nixos then . else - .Config.packages |= - # only add bash if needed to avoid conflicts in profile - if any(endswith("#bash") or endswith("#bashInteractive")) - then . - else . + ["github:NixOS/nixpkgs/\($args.nixpkgsRev)#bash"] - end - end + if .Config.nix_host then + .Env.NIX_CONFIG += "\nextra-substituters = http://cache:7745" + else . end ) ) end )