blob: c370ccb00c8434dea9e005a5582249bfface17ea [file] [log] [blame]
David K. Bainbridge528b3182017-01-23 08:51:59 -08001#!/bin/ash
David K. Bainbridgebe58a0d2016-06-22 15:43:02 -07002
3ID=$1
4HOSTNAME=$2
5IP=$3
6MAC=$4
7ROLE=$5
8
9LOG=/etc/maas/ansible/logs/$ID.log
10
11echo "" >> $LOG
12echo "***** BEGIN *****" >> $LOG
13echo "PROVISION $ID $HOSTNAME $IP $MAC $ROLE" >> $LOG
14
15SKIP_TAGS=
16EXTRA_VARS=--extra-vars=ansible_ssh_pass=onl
17
18echo "ANSIBLE_ROLES_PATH=/etc/maas/ansible/roles ansible-playbook -i $IP, /etc/maas/ansible/switch-node.yml $SKIP_TAGS $EXTRA_VARS" >> $LOG
19ANSIBLE_ROLES_PATH=/etc/maas/ansible/roles ansible-playbook -i $IP, /etc/maas/ansible/switch-node.yml $SKIP_TAGS $EXTRA_VARS >> $LOG
20