Merge "Use openstack-hosted development config"

This commit is contained in:
Zuul 2018-09-27 15:53:59 +00:00 committed by Gerrit Code Review
commit 96df3747f5
8 changed files with 33 additions and 41 deletions

View File

@ -15,10 +15,11 @@ Overview
The kayobe development environment automation tooling is built using simple The kayobe development environment automation tooling is built using simple
shell scripts. Some minimal configuration can be applied by setting the shell scripts. Some minimal configuration can be applied by setting the
environment variables in `dev/config.sh`. Control plane configuration is environment variables in `dev/config.sh`. Control plane configuration is
typically provided via the `dev-kayobe-config typically provided via the `kayobe-config-dev
<https://github.com/stackhpc/dev-kayobe-config/>`_ repository, although it is <https://git.openstack.org/cgit/openstack/kayobe-config-dev>`_ repository,
also possible to use your own kayobe configuration. This allows us to build a although it is also possible to use your own kayobe configuration. This allows
development environment that is as close to production as possible. us to build a development environment that is as close to production as
possible.
Environments Environments
============ ============
@ -46,10 +47,10 @@ Change the current directory to the kayobe repository::
cd kayobe cd kayobe
Clone the ``dev-kayobe-config`` repository to ``config/src/kayobe-config``:: Clone the ``kayobe-config-dev`` repository to ``config/src/kayobe-config``::
mkdir -p config/src mkdir -p config/src
git clone https://github.com/stackhpc/dev-kayobe-config config/src/kayobe-config git clone https://git.openstack.org/openstack/kayobe-config-dev.git config/src/kayobe-config
Inspect the kayobe configuration and make any changes necessary for your Inspect the kayobe configuration and make any changes necessary for your
environment. environment.
@ -112,11 +113,11 @@ Change the current directory to the kayobe repository::
cd kayobe cd kayobe
Clone the ``add-seed-and-hv`` branch of the ``dev-kayobe-config`` repository to Clone the ``add-seed-and-hv`` branch of the ``kayobe-config-dev`` repository to
``config/src/kayobe-config``:: ``config/src/kayobe-config``::
mkdir -p config/src mkdir -p config/src
git clone https://github.com/stackhpc/dev-kayobe-config -b add-seed-and-hv config/src/kayobe-config git clone https://github.com/markgoddard/dev-kayobe-config -b add-seed-and-hv config/src/kayobe-config
Inspect the kayobe configuration and make any changes necessary for your Inspect the kayobe configuration and make any changes necessary for your
environment. environment.
@ -155,11 +156,11 @@ Change to the ``kayobe`` directory::
cd kayobe cd kayobe
Clone the ``add-seed-and-hv`` branch of the ``dev-kayobe-config`` repository to Clone the ``add-seed-and-hv`` branch of the ``kayobe-config-dev`` repository to
``config/src/kayobe-config``:: ``config/src/kayobe-config``::
mkdir -p config/src mkdir -p config/src
git clone https://github.com/stackhpc/dev-kayobe-config -b add-seed-and-hv config/src/kayobe-config git clone https://github.com/markgoddard/dev-kayobe-config -b add-seed-and-hv config/src/kayobe-config
Inspect the kayobe configuration and make any changes necessary for your Inspect the kayobe configuration and make any changes necessary for your
environment. environment.

View File

@ -4,5 +4,5 @@
- role: kayobe-diagnostics - role: kayobe-diagnostics
kayobe_diagnostics_phase: "post" kayobe_diagnostics_phase: "post"
kayobe_diagnostics_log_dir: "/tmp/logs" kayobe_diagnostics_log_dir: "/tmp/logs"
kayobe_diagnostics_config_dir: "{{ zuul.project.src_dir }}/config/src/kayobe-config" kayobe_diagnostics_config_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
kayobe_diagnostics_executor_log_dir: "{{ zuul.executor.log_root }}/{{ inventory_hostname }}" kayobe_diagnostics_executor_log_dir: "{{ zuul.executor.log_root }}/{{ inventory_hostname }}"

View File

@ -2,8 +2,10 @@
- hosts: primary - hosts: primary
vars: vars:
logs_dir: "/tmp/logs" logs_dir: "/tmp/logs"
kayobe_src_dir: "{{ zuul.project.src_dir }}" kayobe_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe'].src_dir }}"
kayobe_config_src_dir: "{{ kayobe_src_dir }}/config/src/kayobe-config" kayobe_config_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
environment:
KAYOBE_CONFIG_SOURCE_PATH: "{{ kayobe_config_src_dir }}"
roles: roles:
- role: kayobe-diagnostics - role: kayobe-diagnostics
kayobe_diagnostics_phase: "pre" kayobe_diagnostics_phase: "pre"
@ -39,16 +41,6 @@
mode: 0644 mode: 0644
remote_src: true remote_src: true
- name: Ensure kayobe-config directory exists
file:
path: "{{ kayobe_config_src_dir }}"
state: directory
- name: Ensure kayobe-config repository is cloned
git:
repo: https://github.com/stackhpc/dev-kayobe-config
dest: "{{ kayobe_config_src_dir }}"
# NOTE(mgoddard): Use the name zz-overrides.yml to ensure this takes # NOTE(mgoddard): Use the name zz-overrides.yml to ensure this takes
# precedence over the standard config files. # precedence over the standard config files.
- name: Ensure kayobe-config override config file exists - name: Ensure kayobe-config override config file exists

View File

@ -1,8 +1,11 @@
--- ---
- hosts: primary - hosts: primary
vars: vars:
kayobe_src_dir: "{{ zuul.project.src_dir }}" kayobe_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe'].src_dir }}"
kayobe_config_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
logs_dir: "/tmp/logs" logs_dir: "/tmp/logs"
environment:
KAYOBE_CONFIG_SOURCE_PATH: "{{ kayobe_config_src_dir }}"
tasks: tasks:
- name: Ensure overcloud is deployed - name: Ensure overcloud is deployed
shell: shell:

View File

@ -4,5 +4,5 @@
- role: kayobe-diagnostics - role: kayobe-diagnostics
kayobe_diagnostics_phase: "post" kayobe_diagnostics_phase: "post"
kayobe_diagnostics_log_dir: "/tmp/logs" kayobe_diagnostics_log_dir: "/tmp/logs"
kayobe_diagnostics_config_dir: "{{ zuul.project.src_dir }}/config/src/kayobe-config" kayobe_diagnostics_config_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
kayobe_diagnostics_executor_log_dir: "{{ zuul.executor.log_root }}/{{ inventory_hostname }}" kayobe_diagnostics_executor_log_dir: "{{ zuul.executor.log_root }}/{{ inventory_hostname }}"

View File

@ -2,8 +2,10 @@
- hosts: primary - hosts: primary
vars: vars:
logs_dir: "/tmp/logs" logs_dir: "/tmp/logs"
kayobe_src_dir: "{{ zuul.project.src_dir }}" kayobe_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe'].src_dir }}"
kayobe_config_src_dir: "{{ kayobe_src_dir }}/config/src/kayobe-config" kayobe_config_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
environment:
KAYOBE_CONFIG_SOURCE_PATH: "{{ kayobe_config_src_dir }}"
roles: roles:
- role: kayobe-diagnostics - role: kayobe-diagnostics
kayobe_diagnostics_phase: "pre" kayobe_diagnostics_phase: "pre"
@ -39,16 +41,6 @@
mode: 0644 mode: 0644
remote_src: true remote_src: true
- name: Ensure kayobe-config directory exists
file:
path: "{{ kayobe_config_src_dir }}"
state: directory
- name: Ensure kayobe-config repository is cloned
git:
repo: https://github.com/stackhpc/dev-kayobe-config
dest: "{{ kayobe_config_src_dir }}"
# NOTE(mgoddard): Use the name zz-overrides.yml to ensure this takes # NOTE(mgoddard): Use the name zz-overrides.yml to ensure this takes
# precedence over the standard config files. # precedence over the standard config files.
- name: Ensure kayobe-config override config file exists - name: Ensure kayobe-config override config file exists

View File

@ -1,13 +1,15 @@
--- ---
- hosts: primary - hosts: primary
vars: vars:
kayobe_src_dir: "{{ zuul.project.src_dir }}" kayobe_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe'].src_dir }}"
kayobe_config_src_dir: "{{ ansible_env.PWD ~ '/' ~ zuul.projects['git.openstack.org/openstack/kayobe-config-dev'].src_dir }}"
logs_dir: "/tmp/logs" logs_dir: "/tmp/logs"
environment:
KAYOBE_CONFIG_SOURCE_PATH: "{{ kayobe_config_src_dir }}"
# Don't provision a seed VM - use the Zuul VM as the seed host.
KAYOBE_SEED_VM_PROVISION: 0
tasks: tasks:
- name: Ensure seed is deployed - name: Ensure seed is deployed
shell: shell:
cmd: dev/seed-deploy.sh > {{ logs_dir }}/ansible/seed-deploy cmd: dev/seed-deploy.sh > {{ logs_dir }}/ansible/seed-deploy
chdir: "{{ kayobe_src_dir }}" chdir: "{{ kayobe_src_dir }}"
environment:
# Don't provision a seed VM - use the Zuul VM as the seed host.
KAYOBE_SEED_VM_PROVISION: 0

View File

@ -40,6 +40,7 @@
attempts: 1 attempts: 1
timeout: 5400 timeout: 5400
required-projects: required-projects:
- name: openstack/kayobe-config-dev
- name: openstack/kolla - name: openstack/kolla
override-checkout: stable/queens override-checkout: stable/queens
- name: openstack/kolla-ansible - name: openstack/kolla-ansible
@ -67,6 +68,7 @@
attempts: 1 attempts: 1
timeout: 5400 timeout: 5400
required-projects: required-projects:
- name: openstack/kayobe-config-dev
- name: openstack/kolla - name: openstack/kolla
override-checkout: stable/queens override-checkout: stable/queens
- name: openstack/kolla-ansible - name: openstack/kolla-ansible