Merge "Check empty passwords in $CONFIG_DIR/passwords.yml"

This commit is contained in:
Jenkins 2016-04-05 11:46:38 +00:00 committed by Gerrit Code Review
commit 4e62c583b5
2 changed files with 4 additions and 4 deletions
ansible/roles/prechecks/tasks
tools

@ -35,8 +35,8 @@
or inventory_hostname in groups['neutron-metadata-agent'])
- ansible_distribution == 'Ubuntu' and ansible_distribution_version == '14.04'
- name: Checking empty passwords in /etc/kolla/passwords.yml. Run kolla-genpwd is this task fails
local_action: command grep '^[^#].*:\s*$' /etc/kolla/passwords.yml
- name: Checking empty passwords in passwords.yml. Run kolla-genpwd if this task fails
local_action: command grep '^[^#].*:\s*$' "{{ CONFIG_DIR }}/passwords.yml"
register: result
changed_when: false
failed_when: result.stdout != ""
failed_when: result.stdout | regex_replace('(.*nova_ssh_key.*)', '') | search(":")

@ -160,6 +160,6 @@ case "$1" in
;;
esac
CONFIG_OPTS="-e @${CONFIG_DIR}/globals.yml -e @${CONFIG_DIR}/passwords.yml"
CONFIG_OPTS="-e @${CONFIG_DIR}/globals.yml -e @${CONFIG_DIR}/passwords.yml -e CONFIG_DIR=${CONFIG_DIR}"
CMD="ansible-playbook -i $INVENTORY $CONFIG_OPTS $EXTRA_OPTS $PLAYBOOK $VERBOSITY"
process_cmd