Force pseudo-terminal when running addhost
so that addhost also works on Debian (also contains another small sync with nunoc-ops).
This commit is contained in:
parent
56c8355c17
commit
3f56de1355
11
addhost
11
addhost
|
@ -37,6 +37,11 @@ defrepo=`git remote -v | grep ${remote:="ro"} | grep fetch | awk '{print $2}'`
|
|||
rrepo=${repo:="$defrepo"}
|
||||
rtag=${tag:="changeme"}
|
||||
|
||||
if [ "x$rrepo" = "x" ]; then
|
||||
echo "$0: repo not set in cosmos.conf and no git remote named 'ro' found"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -d $cmd_hostname ]; then
|
||||
cp -pr default $cmd_fqdn
|
||||
git add $cmd_fqdn
|
||||
|
@ -46,7 +51,7 @@ fi
|
|||
|
||||
if [ "$cmd_do_bootstrap" = "yes" ]; then
|
||||
scp apt/cosmos_1.5-1_all.deb apt/bootstrap-cosmos.sh root@$cmd_hostname:
|
||||
ssh root@$cmd_hostname ./bootstrap-cosmos.sh $cmd_fqdn $rrepo $rtag
|
||||
ssh root@$cmd_hostname cosmos update
|
||||
ssh root@$cmd_hostname cosmos apply
|
||||
ssh -t root@$cmd_hostname ./bootstrap-cosmos.sh $cmd_fqdn $rrepo $rtag
|
||||
ssh -t root@$cmd_hostname cosmos update
|
||||
ssh -t root@$cmd_hostname cosmos apply
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue