diff --git a/runtags b/runtags index 2c85103d2..70f60aa03 100755 --- a/runtags +++ b/runtags @@ -22,6 +22,15 @@ fi tags=$(echo $1 | tr "," "\n") +if [ "$tags" == "" ] +then + echo " usage: ./runtags " + echo " Can take a single value or a comma separated list" + echo " Retrieving a list of possible values" + ansible-playbook -i ansible_hosts iiab.yml --connection=local --list-tag + exit 0 +fi + found="N" for tag in $tags @@ -30,7 +39,6 @@ do then found="Y" fi - done # echo $found @@ -42,12 +50,5 @@ then taglist="prep,"$taglist fi -# script to run a specific tag in the current playbook -if [ $# -ne 1 ]; then - echo "usage: $0 " - echo - echo " If you would like a list of possible values, enter $0 XXX" - exit 1 -fi export ANSIBLE_LOG_PATH="$XSCE_DIR/iiab-debug.log" ansible-playbook -i ansible_hosts iiab.yml --connection=local --tags="""$taglist"""