diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2012-07-09 14:37:00 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2012-07-09 14:37:00 -0300 |
commit | 70602b414634c0827eb809509e72530175ec5cbc (patch) | |
tree | 002cdbce8f844dc0a7231f53de8ad7b6c647747f | |
parent | 32920d1e4ed2d79d1fe3618ed7cdc54fa568634e (diff) | |
download | hydra-70602b414634c0827eb809509e72530175ec5cbc.tar.gz hydra-70602b414634c0827eb809509e72530175ec5cbc.tar.bz2 |
Using temp file for newkeys
-rwxr-xr-x | share/hydra/newkeys | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/share/hydra/newkeys b/share/hydra/newkeys index d742fd9..f6a606f 100755 --- a/share/hydra/newkeys +++ b/share/hydra/newkeys @@ -34,8 +34,14 @@ function hydra_newkeys { function hydra_genpairs { keyringer $HYDRA genpair ssh $node/ssh/id_rsa $host $privkey keyringer $HYDRA genpair gpg $node/gpg/key $host - keyringer $HYDRA git commit # TODO: -m "Importing keys from $host" - keyringer $HYDRA git push + + hydra_set_tmpfile genpair + echo "Importing keys from $host" > $TMPWORK + + keyringer $HYDRA git commit -F $TMPWORK + keyringer $HYDRA git push + + hydra_unset_tmpfile $TMPWORK # Add key into puppet git repository. ( cd $PUPPET_KEYS && git add $(basename $privkey) $(basename $pubkey) ) |