From 1d4ffccdbad2dd614fc3156cf27e68f4c0e5747c Mon Sep 17 00:00:00 2001 From: lassulus Date: Sun, 14 Jun 2015 19:37:30 +0200 Subject: Revert "deploy: take optional target argument" This reverts commit 4846a8e4a8d7c9aeedafa626104a32afaf8d2ab0. --- bin/nixos-deploy | 7 ++++--- deploy | 6 ++++-- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/bin/nixos-deploy b/bin/nixos-deploy index d33e9a1..6b84186 100755 --- a/bin/nixos-deploy +++ b/bin/nixos-deploy @@ -1,12 +1,13 @@ #! /bin/sh # -# usage: nixos-deploy HOST [TARGET] [SYSTEM] +# deploy # set -euf host=$1 -target=${2-root@$host} -system=${3-$(nixos-build "$host")} +system=${2-$(nixos-build "$host")} + +target=root@$host nix-copy-closure --gzip --to "$target" "$system" diff --git a/deploy b/deploy index e99794e..6034196 100755 --- a/deploy +++ b/deploy @@ -1,9 +1,11 @@ #! /bin/sh # -# usage: ./deploy HOST [TARGET] +# usage: ./deploy HOST # set -euf +host=$1 + export PATH="$PWD/bin:$PATH" #export nixpkgs=/var/nixpkgs export nixpkgs_root=$PWD/tmp/nixpkgs @@ -11,4 +13,4 @@ export config_root=$PWD export retiolum_hosts=$PWD/hosts export secrets_root=$PWD/secrets -exec nixos-deploy "$@" +exec nixos-deploy "$host" -- cgit v1.2.3