summaryrefslogtreecommitdiff
path: root/run-single.sh
diff options
context:
space:
mode:
Diffstat (limited to 'run-single.sh')
-rwxr-xr-xrun-single.sh31
1 files changed, 20 insertions, 11 deletions
diff --git a/run-single.sh b/run-single.sh
index 4033b22..4b9ad06 100755
--- a/run-single.sh
+++ b/run-single.sh
@@ -3,7 +3,7 @@
set -eu
-getip()
+getaddr()
{
awk -v "name=$1" '$1 == name { print $2 }' "$hosts_in" |
sed 's/ansible_ssh_host=//'
@@ -13,16 +13,25 @@ getip()
mkhosts()
{
cat <<EOF
-single ansible_ssh_host=$(getip single)
+ick ansible_ssh_host=$(getaddr ick)
-[qvisqve]
-single
+[ickhost]
+ick
[controller]
-single
+ick
+
+[qvisqve]
+ick
+
+[apt]
+ick
+
+[notify]
+ick
[workers]
-single
+ick
EOF
}
@@ -33,9 +42,9 @@ mkhosts > hosts.tmp
ansible-playbook \
-i hosts.tmp \
ick2.yml \
- -e qvisqve_domain="$(getip single)" \
- -e controller_domain="$(getip single)" \
- -e artifact_store_domain="$(getip single)" \
- -e apt_domain="$(getip single)" \
- -e notify_domain="$(getip single)" \
+ -e qvisqve_domain="$(getaddr ick)" \
+ -e controller_domain="$(getaddr ick)" \
+ -e artifact_store_domain="$(getaddr ick)" \
+ -e apt_domain="$(getaddr ick)" \
+ -e notify_domain="$(getaddr ick)" \
"$@"