Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* An appropriate OS has already been installed
* EPEL repositories aren't deployed, they aren't compatible with OpenStack repositories
* The machine running `dev-install` can SSH to the standalone host as either root or a user with passwordless sudo access
* This machine has Ansible installed, and some dependencies like `python3-netaddr`.
* This machine has Ansible installed. Additional dependencies like `python3-netaddr` will be installed automatically.

You need to deploy the right RHEL version depending on which OSP version you want:

Expand Down
8 changes: 4 additions & 4 deletions playbooks/local_os_client.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,14 +97,14 @@

- name: Merge standalone from remote clouds.yaml into local clouds.yaml entry {{ local_cloudname }}
ansible.builtin.set_fact:
cloudsyaml: "{{ cloudsyaml | combine({'clouds': {local_cloudname: standalone}}, recursive=true) }}"
cloudsyaml: "{{ cloudsyaml | combine({'clouds': {local_cloudname + '-admin': standalone}}, recursive=true) }}"
vars:
standalone: "{{ hostvars['standalone']['cloudsyaml']['clouds']['standalone'] | combine(set_cacert) }}"
when: "'standalone' in hostvars['standalone']['cloudsyaml']['clouds']"

- name: Merge openshift from remote clouds.yaml into local clouds.yaml entry {{ local_cloudname }}
ansible.builtin.set_fact:
cloudsyaml: "{{ cloudsyaml | combine({'clouds': {local_cloudname + '_openshift': openshift}}, set_cacert, recursive=true) }}"
cloudsyaml: "{{ cloudsyaml | combine({'clouds': {local_cloudname: openshift}}, set_cacert, recursive=true) }}"
vars:
openshift: "{{ hostvars['standalone']['cloudsyaml']['clouds']['openshift'] | combine(set_cacert) }}"
when: "'openshift' in hostvars['standalone']['cloudsyaml']['clouds']"
Expand All @@ -116,9 +116,9 @@
mode: '0755'

- name: Install openstack client locally
ansible.builtin.pip:
become: true
ansible.builtin.package:
name: python-openstackclient
extra_args: "{% if not is_local_virtualenv %} --user {% endif %}"

- name: Create the scripts if it does not exist
ansible.builtin.file:
Expand Down
11 changes: 11 additions & 0 deletions playbooks/local_requirements.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,14 @@
roles:
- operators
- rhsm
- hosts: localhost
connection: local
become: true
name: Install dependencies for other playbooks
tasks:
- name: Install packages
ansible.builtin.package:
name:
- python3-jmespath
- python3-netaddr
state: installed
3 changes: 0 additions & 3 deletions playbooks/vars/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ rhos_release: 17.1
hostname: standalone
clouddomain: shiftstack

# is ansible running in a virtualenv on the control node
is_local_virtualenv: "{{ lookup('env', 'VIRTUAL_ENV') | default('', true) }}"

# The name of the cloud in *local* clouds.yaml. On the host it will always be
# called `standalone`.
local_cloudname: standalone
Expand Down