Added variables ceph for glance and cinder.

This commit is contained in:
Egon Rijpkema 2018-06-20 16:39:18 +02:00
parent c0555cdcfa
commit 75f384c579
3 changed files with 26 additions and 6 deletions

View File

@ -24,6 +24,11 @@
-e "RABBIT_HOST={{ listen_ip | default(hostvars[groups['rabbitmq'][0]]['ansible_default_ipv4']['address']) }}"
-e "RABBIT_PASSWORD={{ secrets['RABBIT_PASSWORD'] }}"
-e "RABBIT_USER=openstack"
-e "USE_CEPH={{ use_ceph }}"
-e "MON_INITIAL_MEMBERS={{ ceph_mon_initial_members }}"
-e "MON_HOST={{ ceph_mon_host }}"
-e "PUBLIC_NETWORK={{ ceph_public_network }}"
-e "OSD_POOL_DEFAULT_SIZE={{ ceph_osd_pool_default_size }}"
tags: vars
- name: pull docker image
@ -37,9 +42,9 @@
state: directory
mode: 0777
with_items:
- /srv/cinder-storage
- /srv/cinder-storage/root
- /srv/cinder-storage/etc/ceph
- /srv/cinder-storage
- /srv/cinder-storage/root
- /srv/cinder-storage/etc/ceph
- name: initial setup
command: >
@ -62,7 +67,6 @@
dest: /srv/cinder-storage/etc/ceph/ceph.client.volumes.keyring
mode: 0644
- name: install service file.
template:
src: templates/cinder-storage.service
@ -72,6 +76,12 @@
group: root
tags: systemd
- name: set ceph client keyring
copy:
content: "{{ceph_cinder_client_keyring}}"
dest: /srv/cinder-storage/etc/ceph
when: use_ceph
- command: systemctl daemon-reload
tags: systemd

View File

@ -19,7 +19,11 @@
-e "RABBIT_HOST={{ listen_ip | default(hostvars[groups['rabbitmq'][0]]['ansible_default_ipv4']['address']) }}"
-e "RABBIT_PASSWORD={{ secrets['RABBIT_PASSWORD'] }}"
-e "RABBIT_USER=openstack"
-e "USE_CEPH={{ use_ceph }}"
-e "MON_INITIAL_MEMBERS={{ ceph_mon_initial_members }}"
-e "MON_HOST={{ ceph_mon_host }}"
-e "PUBLIC_NETWORK={{ ceph_public_network }}"
-e "OSD_POOL_DEFAULT_SIZE={{ ceph_osd_pool_default_size }}"
#- name: pull docker image
# docker_image:
@ -48,6 +52,12 @@
dest: /srv/glance/etc/ceph/ceph.client.volumes.keyring
mode: 0644
- name: set ceph client keyring
copy:
content: "{{ceph_images_client_keyring}}"
dest: /srv/cinder-storage/etc/ceph/ceph.client.images.keyring
when: use_ceph
- name: install service file.
template:
src: templates/glance.service

View File

@ -48,7 +48,7 @@
- name: set ceph client keyring
copy:
content: "{{ceph_client_keyring}}"
content: "{{ceph_compute_client_keyring}}"
dest: /srv/nova-compute/etc/ceph
when: use_ceph