summaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/config-osa
diff options
context:
space:
mode:
Diffstat (limited to 'deploy/adapters/ansible/roles/config-osa')
-rw-r--r--deploy/adapters/ansible/roles/config-osa/tasks/fix_rescue.yml43
-rwxr-xr-xdeploy/adapters/ansible/roles/config-osa/tasks/main.yml18
-rw-r--r--deploy/adapters/ansible/roles/config-osa/templates/user_variables.yml.j22
3 files changed, 62 insertions, 1 deletions
diff --git a/deploy/adapters/ansible/roles/config-osa/tasks/fix_rescue.yml b/deploy/adapters/ansible/roles/config-osa/tasks/fix_rescue.yml
new file mode 100644
index 00000000..eea06b48
--- /dev/null
+++ b/deploy/adapters/ansible/roles/config-osa/tasks/fix_rescue.yml
@@ -0,0 +1,43 @@
+---
+
+- name: fix rescue problem for openstack-hosts-setup
+ blockinfile:
+ dest: "/opt/openstack-ansible/playbooks/openstack-hosts-setup.yml"
+ block: |
+ - hosts: localhost
+ user: root
+ tasks:
+ - name: Mark openstack-hosts-setup completed
+ shell: echo "Setup openstack-hosts-setup completed!"
+
+- name: delete max_fail_percentage for openstack-hosts-setup
+ lineinfile:
+ dest: "/opt/openstack-ansible/playbooks/openstack-hosts-setup.yml"
+ regexp: "max_fail_percentage*"
+ state: absent
+
+- name: fix rescue problem for security-hardening
+ blockinfile:
+ dest: "/opt/openstack-ansible/playbooks/security-hardening.yml"
+ block: |
+ - hosts: localhost
+ user: root
+ tasks:
+ - name: Mark security-hardening completed
+ shell: echo "Setup security-hardening completed!"
+
+- name: fix rescue problem for lxc-hosts-setup
+ blockinfile:
+ dest: "/opt/openstack-ansible/playbooks/lxc-hosts-setup.yml"
+ block: |
+ - hosts: localhost
+ user: root
+ tasks:
+ - name: Mark lxc-hosts-setup completed
+ shell: echo "Setup lxc-hosts-setup completed!"
+
+- name: delete max_fail_percentage for lxc-hosts-setup
+ lineinfile:
+ dest: "/opt/openstack-ansible/playbooks/lxc-hosts-setup.yml"
+ regexp: "max_fail_percentage*"
+ state: absent
diff --git a/deploy/adapters/ansible/roles/config-osa/tasks/main.yml b/deploy/adapters/ansible/roles/config-osa/tasks/main.yml
index cdf11421..046b25e5 100755
--- a/deploy/adapters/ansible/roles/config-osa/tasks/main.yml
+++ b/deploy/adapters/ansible/roles/config-osa/tasks/main.yml
@@ -47,6 +47,22 @@
- offline_deployment is defined and offline_deployment == "Disable"
- hostvars[hostvars[inventory_hostname]['groups']['controller'][0]]['local_mirror'] == 'Ubuntu'
+- name: add libvirt into cinder packages
+ lineinfile:
+ dest: /etc/ansible/roles/os_cinder/vars/redhat-7.yml
+ insertafter: '^ - qemu-img-ev'
+ line: ' - libvirt'
+
+- name: remove CentOS-Base.repo after ceph-osd
+ blockinfile:
+ dest: /etc/ansible/roles/ceph-osd/tasks/start_osds.yml
+ block: |
+ - name: remove empty yum base repo
+ shell: |
+ mv /etc/yum.repos.d/CentOS-Base.repo \
+ /etc/yum.repos.d/CentOS-Base.repo.bak;
+ when: hostvars[hostvars[inventory_hostname]['groups']['controller'][0]]['local_mirror'] == 'CentOS'
+
- name: add mariadb local repository
blockinfile:
dest: /etc/openstack_deploy/user_variables.yml
@@ -284,3 +300,5 @@
dest: /etc/ansible/roles/os_keystone/defaults/main.yml
regexp: '^ - python-ldap'
line: ' - python-ldap==2.5.2'
+
+- include: fix_rescue.yml
diff --git a/deploy/adapters/ansible/roles/config-osa/templates/user_variables.yml.j2 b/deploy/adapters/ansible/roles/config-osa/templates/user_variables.yml.j2
index a6e69683..88a3233b 100644
--- a/deploy/adapters/ansible/roles/config-osa/templates/user_variables.yml.j2
+++ b/deploy/adapters/ansible/roles/config-osa/templates/user_variables.yml.j2
@@ -62,4 +62,4 @@ neutron_provider_networks:
network_mappings: "{{ ','.join(controller_mappings) }}"
{% endif %}
-security_sshd_permit_root_login: no
+security_sshd_permit_root_login: yes