novajoin/roles/configure-novajoin/tasks/main.yaml

56 lines
1.4 KiB
YAML

- name: Build novajoin
command: python setup.py build
args:
chdir: '{{ zuul.project.src_dir }}'
- name: Install novajoin
command: python setup.py install
args:
chdir: '{{ zuul.project.src_dir }}'
become: true
- name: Configure novajoin
shell: >
source /opt/stack/devstack/openrc admin admin &&
novajoin-install --debug --principal admin --password password
--user stack --nova-password secretservice
--keystone-auth-url http://127.0.0.1/identity
args:
executable: /bin/bash
become: true
- name: Create novajoin log directory
file:
path: /var/log/novajoin
state: directory
owner: stack
become: true
- name: Start novajoin-server
shell: nohup novajoin-server --debug </dev/null >/dev/null 2>&1 &
become: true
become_user: stack
- name: Start novajoin-notify
shell: nohup novajoin-notify --debug </dev/null >/dev/null 2>&1 &
become: true
become_user: stack
- name: Restart nova services
command: systemctl restart devstack@n-*
become: true
- name: Set FreeIPA DNS in demo private-subnet
shell: >
source /opt/stack/devstack/openrc demo demo &&
openstack subnet set --no-dns-nameservers private-subnet &&
openstack subnet set --dns-nameserver {{ ansible_default_ipv4.address }} private-subnet
args:
executable: /bin/bash
- name: Chmod /etc/novajoin/krb5.keytab for use by tests
file:
path: /etc/novajoin/krb5.keytab
mode: 0644
become: true