Merge "Fix parameter issue in cinder handlers"
This commit is contained in:
commit
747b100e48
@ -755,6 +755,9 @@ def generate_module():
|
|||||||
# if pid_mode = ""/None/False, remove it
|
# if pid_mode = ""/None/False, remove it
|
||||||
if not new_args.get('pid_mode', False):
|
if not new_args.get('pid_mode', False):
|
||||||
new_args.pop('pid_mode', None)
|
new_args.pop('pid_mode', None)
|
||||||
|
# if ipc_mode = ""/None/False, remove it
|
||||||
|
if not new_args.get('ipc_mode', False):
|
||||||
|
new_args.pop('ipc_mode', None)
|
||||||
|
|
||||||
module.params = new_args
|
module.params = new_args
|
||||||
return module
|
return module
|
||||||
|
@ -25,6 +25,8 @@ cinder_services:
|
|||||||
group: cinder-volume
|
group: cinder-volume
|
||||||
enabled: true
|
enabled: true
|
||||||
image: "{{ cinder_volume_image_full }}"
|
image: "{{ cinder_volume_image_full }}"
|
||||||
|
privileged: True
|
||||||
|
ipc_mode: "host"
|
||||||
volumes:
|
volumes:
|
||||||
- "{{ node_config_directory }}/cinder-volume/:{{ container_config_directory }}/:ro"
|
- "{{ node_config_directory }}/cinder-volume/:{{ container_config_directory }}/:ro"
|
||||||
- "/etc/localtime:/etc/localtime:ro"
|
- "/etc/localtime:/etc/localtime:ro"
|
||||||
@ -38,6 +40,7 @@ cinder_services:
|
|||||||
group: cinder-backup
|
group: cinder-backup
|
||||||
enabled: true
|
enabled: true
|
||||||
image: "{{ cinder_backup_image_full }}"
|
image: "{{ cinder_backup_image_full }}"
|
||||||
|
privileged: True
|
||||||
volumes:
|
volumes:
|
||||||
- "{{ node_config_directory }}/cinder-backup/:{{ container_config_directory }}/:ro"
|
- "{{ node_config_directory }}/cinder-backup/:{{ container_config_directory }}/:ro"
|
||||||
- "/etc/localtime:/etc/localtime:ro"
|
- "/etc/localtime:/etc/localtime:ro"
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
common_options: "{{ docker_common_options }}"
|
common_options: "{{ docker_common_options }}"
|
||||||
name: "{{ service.container_name }}"
|
name: "{{ service.container_name }}"
|
||||||
image: "{{ service.image }}"
|
image: "{{ service.image }}"
|
||||||
volumes: "{{ service.volumes }}"
|
volumes: "{{ service.volumes | reject('equalto', '') | list }}"
|
||||||
when:
|
when:
|
||||||
- action != "config"
|
- action != "config"
|
||||||
- inventory_hostname in groups[service.group]
|
- inventory_hostname in groups[service.group]
|
||||||
@ -20,7 +20,7 @@
|
|||||||
- config_json.changed | bool
|
- config_json.changed | bool
|
||||||
or cinder_conf.changed | bool
|
or cinder_conf.changed | bool
|
||||||
or policy_json.changed | bool
|
or policy_json.changed | bool
|
||||||
or cinder_api_container.changed |
|
or cinder_api_container.changed | bool
|
||||||
|
|
||||||
- name: Restart cinder-scheduler container
|
- name: Restart cinder-scheduler container
|
||||||
vars:
|
vars:
|
||||||
@ -35,7 +35,7 @@
|
|||||||
common_options: "{{ docker_common_options }}"
|
common_options: "{{ docker_common_options }}"
|
||||||
name: "{{ service.container_name }}"
|
name: "{{ service.container_name }}"
|
||||||
image: "{{ service.image }}"
|
image: "{{ service.image }}"
|
||||||
volumes: "{{ service.volumes }}"
|
volumes: "{{ service.volumes | reject('equalto', '') | list }}"
|
||||||
when:
|
when:
|
||||||
- action != "config"
|
- action != "config"
|
||||||
- inventory_hostname in groups[service.group]
|
- inventory_hostname in groups[service.group]
|
||||||
@ -58,7 +58,9 @@
|
|||||||
common_options: "{{ docker_common_options }}"
|
common_options: "{{ docker_common_options }}"
|
||||||
name: "{{ service.container_name }}"
|
name: "{{ service.container_name }}"
|
||||||
image: "{{ service.image }}"
|
image: "{{ service.image }}"
|
||||||
volumes: "{{ service.volumes }}"
|
privileged: "{{ service.privileged | default(False) }}"
|
||||||
|
ipc_mode: "{{ service.ipc_mode | default('') }}"
|
||||||
|
volumes: "{{ service.volumes | reject('equalto', '') | list }}"
|
||||||
when:
|
when:
|
||||||
- action != "config"
|
- action != "config"
|
||||||
- inventory_hostname in groups[service.group]
|
- inventory_hostname in groups[service.group]
|
||||||
@ -81,7 +83,8 @@
|
|||||||
common_options: "{{ docker_common_options }}"
|
common_options: "{{ docker_common_options }}"
|
||||||
name: "{{ service.container_name }}"
|
name: "{{ service.container_name }}"
|
||||||
image: "{{ service.image }}"
|
image: "{{ service.image }}"
|
||||||
volumes: "{{ service.volumes }}"
|
privileged: "{{ service.privileged | default(False) }}"
|
||||||
|
volumes: "{{ service.volumes | reject('equalto', '') | list }}"
|
||||||
when:
|
when:
|
||||||
- action != "config"
|
- action != "config"
|
||||||
- inventory_hostname in groups[service.group]
|
- inventory_hostname in groups[service.group]
|
||||||
|
@ -85,7 +85,9 @@
|
|||||||
common_options: "{{ docker_common_options }}"
|
common_options: "{{ docker_common_options }}"
|
||||||
name: "{{ item.value.container_name }}"
|
name: "{{ item.value.container_name }}"
|
||||||
image: "{{ item.value.image }}"
|
image: "{{ item.value.image }}"
|
||||||
volumes: "{{ item.value.volumes }}"
|
volumes: "{{ item.value.volumes | reject('equalto', '') | list }}"
|
||||||
|
privileged: "{{ item.value.privileged | default(False) }}"
|
||||||
|
ipc_mode: "{{ item.value.ipc_mode | default('') }}"
|
||||||
register: check_cinder_containers
|
register: check_cinder_containers
|
||||||
when:
|
when:
|
||||||
- action != "config"
|
- action != "config"
|
||||||
|
Loading…
Reference in New Issue
Block a user