Merge "Fix keystone nginx behaviour"

This commit is contained in:
Zuul 2020-10-06 17:33:15 +00:00 committed by Gerrit Code Review
commit 89119bb5f8

View File

@ -18,6 +18,7 @@
name: "{{ keystone_system_service_name }}" name: "{{ keystone_system_service_name }}"
state: stopped state: stopped
failed_when: false failed_when: false
when: ('horizon_all' in groups and inventory_hostname not in groups['horizon_all']) or ('horizon_all' not in groups)
- name: Disable default configuration - name: Disable default configuration
file: file:
@ -35,6 +36,18 @@
- Manage LB - Manage LB
- Restart web server - Restart web server
- name: Ensure nginx does not listen on 80 port
replace:
path: /etc/nginx/nginx.conf
regexp: "{{ item.regexp }}"
replace: "{{ item.replace }}"
validate: nginx -t -c %s
with_items:
- regexp: '(\s+listen\s+)[\[,\],:]+80'
replace: '\1 [::1]:8008'
- regexp: '(\s+listen\s+)80'
replace: '\1 127.0.0.1:8008'
- name: Ensure configuration directories exist - name: Ensure configuration directories exist
file: file:
path: "{{ item }}" path: "{{ item }}"