
This update is for providing a dedicated devstack installer for Tacker. It is configurable for supporting several usecases, such as multiple nodes configuration. It's also supports both of default distros in OpenStack, Ubuntu 20.04 (focal) and CentOS Stream 8 currently. You can find usages in the contributor guide `Devstack Installation with Vagrant`. Signed-off-by: Yasufumi Ogawa <yasufum.o@gmail.com> Implements: bp intro-tacker-installer Change-Id: I2f9fcf0811c41d9278df79b5a7e60d608d23cd76
66 lines
2.3 KiB
YAML
66 lines
2.3 KiB
YAML
---
|
|
- name: git clone tacker
|
|
git:
|
|
repo=https://opendev.org/openstack/tacker.git
|
|
dest={{ ansible_env.HOME }}/tacker
|
|
|
|
- name: copy local.conf
|
|
shell: cp {{ ansible_env.HOME }}/tacker/devstack/{{ item }} \
|
|
{{ ansible_env.HOME }}/devstack/{{ item }}
|
|
with_items:
|
|
- local.conf.example
|
|
- local.conf.kubernetes
|
|
|
|
- name: update HOST_IP in devstack/local.conf.example
|
|
lineinfile:
|
|
path={{ ansible_env.HOME }}/devstack/{{ item }}
|
|
line='HOST_IP={{ ansible_host }}'
|
|
regexp='^HOST_IP=127\.0\.0\.1'
|
|
with_items:
|
|
- local.conf.example
|
|
- local.conf.kubernetes
|
|
|
|
- name: update other params in devstack/local.conf.example
|
|
lineinfile:
|
|
path={{ ansible_env.HOME }}/devstack/local.conf.example
|
|
line={{ item.line }}
|
|
regexp={{ item.regexp }}
|
|
with_items:
|
|
- line: 'ADMIN_PASSWORD={{ admin_password }}'
|
|
regexp: '^ADMIN_PASSWORD=devstack'
|
|
- line: 'MYSQL_PASSWORD={{ database_password }}'
|
|
regexp: '^MYSQL_PASSWORD=devstack'
|
|
- line: 'RABBIT_PASSWORD={{ rabbit_password }}'
|
|
regexp: '^RABBIT_PASSWORD=devstack'
|
|
- line: 'SERVICE_PASSWORD={{ service_password }}'
|
|
regexp: '^SERVICE_PASSWORD=\$ADMIN_PASSWORD'
|
|
- line: 'SERVICE_TOKEN={{ service_token }}'
|
|
regexp: '^SERVICE_TOKEN=devstack'
|
|
|
|
- name: update HOST_IP in devstack/local.conf.kubernetes
|
|
lineinfile:
|
|
path={{ ansible_env.HOME }}/devstack/local.conf.kubernetes
|
|
line='HOST_IP={{ service_host }}'
|
|
regexp='^HOST_IP=127\.0\.0\.1'
|
|
|
|
- name: update other params in devstack/local.conf.kubernetes
|
|
lineinfile:
|
|
path={{ ansible_env.HOME }}/devstack/local.conf.kubernetes
|
|
line={{ item.line }}
|
|
regexp={{ item.regexp }}
|
|
with_items:
|
|
- line: 'ADMIN_PASSWORD={{ admin_password }}'
|
|
regexp: '^ADMIN_PASSWORD=devstack'
|
|
- line: 'MYSQL_PASSWORD={{ database_password }}'
|
|
regexp: '^MYSQL_PASSWORD=devstack'
|
|
- line: 'RABBIT_PASSWORD={{ rabbit_password }}'
|
|
regexp: '^RABBIT_PASSWORD=devstack'
|
|
- line: 'SERVICE_PASSWORD={{ service_password }}'
|
|
regexp: '^SERVICE_PASSWORD=\$ADMIN_PASSWORD'
|
|
- line: 'SERVICE_TOKEN={{ service_token }}'
|
|
regexp: '^SERVICE_TOKEN=devstack'
|
|
|
|
- name: use local.conf.example as local.conf
|
|
shell: cp {{ ansible_env.HOME }}/devstack/local.conf.example \
|
|
{{ ansible_env.HOME }}/devstack/local.conf
|