diff options
-rwxr-xr-x | nixops/scripts/setup | 2 | ||||
-rw-r--r-- | scripts/nix_env | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/nixops/scripts/setup b/nixops/scripts/setup index cc03482..dce8332 100755 --- a/nixops/scripts/setup +++ b/nixops/scripts/setup | |||
@@ -94,9 +94,9 @@ if nix show-config --json | jq -e '.sandbox.value == "true"' >/dev/null; then | |||
94 | fi | 94 | fi |
95 | 95 | ||
96 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" | 96 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" |
97 | source $(dirname $(dirname $DIR))/scripts/nix_env | ||
98 | export NIXOPS_STATE="$(dirname $DIR)/state/eldiron.nixops" | 97 | export NIXOPS_STATE="$(dirname $DIR)/state/eldiron.nixops" |
99 | export NIXOPS_DEPLOYMENT="$DeploymentUuid" | 98 | export NIXOPS_DEPLOYMENT="$DeploymentUuid" |
99 | source $(dirname $(dirname $DIR))/scripts/nix_env | ||
100 | 100 | ||
101 | if ! nixops_custom info 2>/dev/null >/dev/null; then | 101 | if ! nixops_custom info 2>/dev/null >/dev/null; then |
102 | cat <<-EOF | 102 | cat <<-EOF |
diff --git a/scripts/nix_env b/scripts/nix_env index 6326243..fc6557c 100644 --- a/scripts/nix_env +++ b/scripts/nix_env | |||
@@ -11,7 +11,7 @@ nixpkgsNext="$nixpkgs" | |||
11 | export NIX_PATH="nixpkgs=$nixpkgs:nixpkgsNext=$nixpkgsNext:nixpkgsPrevious=$nixpkgsPrevious" | 11 | export NIX_PATH="nixpkgs=$nixpkgs:nixpkgsNext=$nixpkgsNext:nixpkgsPrevious=$nixpkgsPrevious" |
12 | 12 | ||
13 | nixops_custom () { | 13 | nixops_custom () { |
14 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" | 14 | _DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" |
15 | d=$(nix-build --no-out-link -E "with import <nixpkgs> { overlays = builtins.attrValues (import $(dirname $DIR)/overlays); }; nixops") | 15 | d=$(nix-build --no-out-link -E "with import <nixpkgs> { overlays = builtins.attrValues (import $(dirname $_DIR)/overlays); }; nixops") |
16 | ${d}/bin/nixops "$@" | 16 | ${d}/bin/nixops "$@" |
17 | } | 17 | } |