From 2fd200e3c58ae504a8c3740d62990997b5349b20 Mon Sep 17 00:00:00 2001 From: Jonathan Rosser Date: Tue, 3 Sep 2024 15:05:00 +0100 Subject: [PATCH] Add setup_hosts playbook to plugins collection. This is the same functionality as in the openstack-ansible repo setup-hosts playbook, end eventually will be called by it. Change-Id: Ie591aa51b16f0d6ae48f1e83e7b103ead5459312 --- playbooks/hook_dummy.yml | 3 +++ playbooks/setup_hosts.yml | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 playbooks/hook_dummy.yml create mode 100644 playbooks/setup_hosts.yml diff --git a/playbooks/hook_dummy.yml b/playbooks/hook_dummy.yml new file mode 100644 index 00000000..a5816056 --- /dev/null +++ b/playbooks/hook_dummy.yml @@ -0,0 +1,3 @@ +- name: Placeholder hook + hosts: localhost + gather_facts: false diff --git a/playbooks/setup_hosts.yml b/playbooks/setup_hosts.yml new file mode 100644 index 00000000..ea457a35 --- /dev/null +++ b/playbooks/setup_hosts.yml @@ -0,0 +1,38 @@ +--- +# Copyright 2014, Rackspace US, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +- name: Importing pre hook playbook + import_playbook: "{{ pre_setup_hosts_hook | default('openstack.osa.hook_dummy') }}" + +- name: Importing certificate_authority playbook + import_playbook: openstack.osa.certificate_authority + +- name: Importing certificate_ssh_authority playbook + import_playbook: openstack.osa.certificate_ssh_authority + +- name: Importing certificate_generate playbook + import_playbook: openstack.osa.certificate_generate + +- name: Importing openstack_hosts_setup playbook + import_playbook: openstack.osa.openstack_hosts_setup + +- name: Importing containers_deploy playbook + import_playbook: openstack.osa.containers_deploy + +- name: Importing security-hardening playbook + import_playbook: openstack.osa.security_hardening + +- name: Importing post hook playbook + import_playbook: "{{ post_setup_hosts_hook | default('openstack.osa.hook_dummy') }}"