Add dev mode for glance

Allows users to develop on Glance using Kolla.

Change-Id: I2c7c97ddf84ca19505cf01adaf982c6a3f70d7d0
Partially-Implements: blueprint mount-sources
This commit is contained in:
Paul Bourke 2017-08-17 14:36:52 +01:00
parent 5cff57ae4e
commit dbe7b591d4
4 changed files with 24 additions and 0 deletions

View File

@ -11,6 +11,7 @@ glance_services:
- "{{ node_config_directory }}/glance-api/:{{ container_config_directory }}/:ro"
- "/etc/localtime:/etc/localtime:ro"
- "{{ glance_file_datadir_volume }}:/var/lib/glance/"
- "{{ kolla_dev_repos_directory ~ '/glance/glance:/var/lib/kolla/venv/lib/python2.7/site-packages/glance' if glance_dev_mode | bool else '' }}"
- "kolla_logs:/var/log/kolla/"
glance-registry:
container_name: glance_registry
@ -90,6 +91,13 @@ glance_keystone_user: "glance"
openstack_glance_auth: "{{ openstack_auth }}"
###################
# Kolla
####################
glance_git_repository: "{{ kolla_dev_repos_git }}/{{ project_name }}"
glance_dev_repos_pull: "{{ kolla_dev_repos_pull }}"
glance_dev_mode: "{{ kolla_dev_mode }}"
################################################
# VMware - OpenStack VMware support
################################################

View File

@ -0,0 +1,6 @@
---
- name: Cloning source repositories for development
git:
repo: "{{ glance_git_repository }}"
dest: "{{ kolla_dev_repos_directory }}/{{ project_name }}"
update: "{{ glance_dev_repos_pull }}"

View File

@ -19,6 +19,12 @@
when: inventory_hostname in groups['glance-api'] or
inventory_hostname in groups['glance-registry']
- include: clone.yml
when:
- glance_dev_mode | bool
- inventory_hostname in groups['glance-api'] or
inventory_hostname in groups['glance-registry']
- include: bootstrap.yml
when: inventory_hostname in groups['glance-api']

View File

@ -0,0 +1,4 @@
---
features:
- |
Glance can now be developed on using Kolla 'dev mode'.