dev mode: Add support for kuryr
Provide support for kolla dev mode in Kuryr. When 'kolla_dev_mode' or 'kuryr_dev_mode' variables are enabled, source code of Kuryr project is cloned and bindmounted. Partially implements: blueprint mount-sources Change-Id: I74c1ea70b4220a0e91f19403971303ca55652371
This commit is contained in:
parent
21372339e7
commit
e4c7b50320
@ -1,5 +1,6 @@
|
||||
---
|
||||
project_name: "kuryr"
|
||||
libnetwork_project_name: "kuryr-libnetwork"
|
||||
|
||||
# NOTE(huikang, apuimedo): when you request a driver in a docker operation, such
|
||||
# as docker network create, docker searches /usr/lib/docker or /etc/docker
|
||||
@ -22,6 +23,8 @@ kuryr_services:
|
||||
- "/lib/modules:/lib/modules:ro"
|
||||
- "/run:/run:shared"
|
||||
- "/usr/lib/docker:/usr/lib/docker"
|
||||
- "{{ kolla_dev_repos_directory ~ '/kuryr/kuryr:/var/lib/kolla/venv/lib/python2.7/site-packages/kuryr' if kuryr_dev_mode | bool else '' }}"
|
||||
- "{{ kolla_dev_repos_directory ~ '/kuryr-libnetwork/kuryr_libnetwork:/var/lib/kolla/venv/lib/python2.7/site-packages/kuryr_libnetwork' if kuryr_dev_mode | bool else '' }}"
|
||||
- "kolla_logs:/var/log/kolla/"
|
||||
|
||||
|
||||
@ -41,3 +44,12 @@ kuryr_logging_debug: "{{ openstack_logging_debug }}"
|
||||
kuryr_keystone_user: "kuryr"
|
||||
|
||||
openstack_kuryr_auth: "{{ openstack_auth }}"
|
||||
|
||||
|
||||
####################
|
||||
# Kolla
|
||||
####################
|
||||
kuryr_git_repository: "{{ kolla_dev_repos_git }}/{{ project_name }}"
|
||||
kuryr_libnetwork_git_repository: "{{ kolla_dev_repos_git }}/{{ libnetwork_project_name }}"
|
||||
kuryr_dev_repos_pull: "{{ kolla_dev_repos_pull }}"
|
||||
kuryr_dev_mode: "{{ kolla_dev_mode }}"
|
||||
|
12
ansible/roles/kuryr/tasks/clone.yml
Normal file
12
ansible/roles/kuryr/tasks/clone.yml
Normal file
@ -0,0 +1,12 @@
|
||||
---
|
||||
- name: Cloning kuryr source repository for development
|
||||
git:
|
||||
repo: "{{ kuryr_git_repository }}"
|
||||
dest: "{{ kolla_dev_repos_directory }}/{{ project_name }}"
|
||||
update: "{{ kuryr_dev_repos_pull }}"
|
||||
|
||||
- name: Cloning kuryr-libnetwork source repository for development
|
||||
git:
|
||||
repo: "{{ kuryr_libnetwork_git_repository }}"
|
||||
dest: "{{ kolla_dev_repos_directory }}/{{ libnetwork_project_name }}"
|
||||
update: "{{ kuryr_dev_repos_pull }}"
|
@ -3,5 +3,9 @@
|
||||
|
||||
- include: config.yml
|
||||
|
||||
- include: clone.yml
|
||||
when:
|
||||
- kuryr_dev_mode | bool
|
||||
|
||||
- name: Flush handlers
|
||||
meta: flush_handlers
|
||||
|
Loading…
Reference in New Issue
Block a user