Fix Cinder commands

This change forces the use of Bash when running the cinder client. This
is required because the command starts with 'source keystonerc' which is
Bash-specific.

Change-Id: I6e720a6b666772357842729dc95ebc5ef6301c39
This commit is contained in:
Simon Pasquier 2016-11-28 13:26:12 +01:00
parent ea24d9cf37
commit 822bb4d9d5
1 changed files with 4 additions and 0 deletions

View File

@ -57,6 +57,7 @@ cinder_type_create_{{ backend_name }}:
cmd.run:
- name: "source /root/keystonerc; cinder type-create {{ backend.type_name }}"
- unless: "source /root/keystonerc; cinder type-list | grep {{ backend.type_name }}"
- shell: /bin/bash
- require:
- service: cinder_controller_services
@ -64,6 +65,7 @@ cinder_type_update_{{ backend_name }}:
cmd.run:
- name: "source /root/keystonerc; cinder type-key {{ backend.type_name }} set volume_backend_name={{ backend_name }}"
- unless: "source /root/keystonerc; cinder extra-specs-list | grep \"{u'volume_backend_name': u'{{ backend_name }}'}\""
- shell: /bin/bash
- require:
- cmd: cinder_type_create_{{ backend_name }}
@ -79,6 +81,7 @@ cinder_type_create_{{ type.name }}:
cmd.run:
- name: "source /root/keystonerc; cinder type-create {{ type.name }}"
- unless: "source /root/keystonerc; cinder type-list | grep {{ type.name }}"
- shell: /bin/bash
- require:
- service: cinder_controller_services
@ -86,6 +89,7 @@ cinder_type_update_{{ type.name }}:
cmd.run:
- name: "source /root/keystonerc; cinder type-key {{ type.name }} set volume_backend_name={{ type.get('backend', type.name) }}"
- unless: "source /root/keystonerc; cinder extra-specs-list | grep \"{u'volume_backend_name': u'{{ type.get('backend', type.name) }}'}\""
- shell: /bin/bash
- require:
- cmd: cinder_type_create_{{ type.name }}