diff --git a/ansible/group_vars/all.yml b/ansible/group_vars/all.yml index 4944742987..42a22f6226 100644 --- a/ansible/group_vars/all.yml +++ b/ansible/group_vars/all.yml @@ -380,7 +380,10 @@ storm_worker_port_range: start: 6700 end: 6703 +swift_internal_fqdn: "{{ kolla_internal_fqdn }}" +swift_external_fqdn: "{{ kolla_external_fqdn }}" swift_proxy_server_port: "8080" +swift_proxy_server_listen_port: "{{ swift_proxy_server_port }}" swift_object_server_port: "6000" swift_account_server_port: "6001" swift_container_server_port: "6002" diff --git a/ansible/roles/cinder/templates/cinder.conf.j2 b/ansible/roles/cinder/templates/cinder.conf.j2 index 6eef0f113c..789010084f 100644 --- a/ansible/roles/cinder/templates/cinder.conf.j2 +++ b/ansible/roles/cinder/templates/cinder.conf.j2 @@ -42,7 +42,7 @@ backup_share = {{ cinder_backup_share }} backup_file_size = 327680000 {% elif enable_swift | bool and cinder_backup_driver == "swift" %} backup_driver = cinder.backup.drivers.swift.SwiftBackupDriver -backup_swift_url = http://{{ kolla_internal_vip_address }}:{{ swift_proxy_server_port }}/v1/AUTH_ +backup_swift_url = {{ internal_protocol }}://{{ swift_internal_fqdn }}:{{ swift_proxy_server_port }}/v1/AUTH_ backup_swift_auth = per_user backup_swift_auth_version = 1 backup_swift_user = diff --git a/ansible/roles/swift/defaults/main.yml b/ansible/roles/swift/defaults/main.yml index 30aa7ed40c..d1d7d31386 100644 --- a/ansible/roles/swift/defaults/main.yml +++ b/ansible/roles/swift/defaults/main.yml @@ -10,12 +10,12 @@ swift_services: enabled: "{{ enable_swift }}" mode: "http" external: false - port: "{{ swift_proxy_server_port }}" + port: "{{ swift_proxy_server_listen_port }}" swift_api_external: enabled: "{{ enable_swift }}" mode: "http" external: true - port: "{{ swift_proxy_server_port }}" + port: "{{ swift_proxy_server_listen_port }}" #################### # Docker @@ -52,9 +52,9 @@ swift_log_level: "{{ 'INFO' if openstack_logging_debug == 'False' else 'DEBUG'}} #################### # OpenStack #################### -swift_admin_endpoint: "{{ admin_protocol }}://{{ kolla_internal_fqdn }}:{{ swift_proxy_server_port }}/v1" -swift_internal_endpoint: "{{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ swift_proxy_server_port }}/v1/AUTH_%(tenant_id)s" -swift_public_endpoint: "{{ public_protocol }}://{{ kolla_external_fqdn }}:{{ swift_proxy_server_port }}/v1/AUTH_%(tenant_id)s" +swift_admin_endpoint: "{{ admin_protocol }}://{{ swift_internal_fqdn }}:{{ swift_proxy_server_port }}/v1" +swift_internal_endpoint: "{{ internal_protocol }}://{{ swift_internal_fqdn }}:{{ swift_proxy_server_port }}/v1/AUTH_%(tenant_id)s" +swift_public_endpoint: "{{ public_protocol }}://{{ swift_external_fqdn }}:{{ swift_proxy_server_port }}/v1/AUTH_%(tenant_id)s" swift_logging_debug: "{{ openstack_logging_debug }}" diff --git a/ansible/roles/swift/tasks/precheck.yml b/ansible/roles/swift/tasks/precheck.yml index 50291c03c9..dc53cabf3c 100644 --- a/ansible/roles/swift/tasks/precheck.yml +++ b/ansible/roles/swift/tasks/precheck.yml @@ -55,7 +55,7 @@ - name: Checking free port for Swift Proxy Server wait_for: host: "{{ api_interface_address }}" - port: "{{ swift_proxy_server_port }}" + port: "{{ swift_proxy_server_listen_port }}" connect_timeout: 1 timeout: 1 state: stopped diff --git a/ansible/roles/swift/templates/proxy-server.conf.j2 b/ansible/roles/swift/templates/proxy-server.conf.j2 index 84067cf006..c842c556a8 100644 --- a/ansible/roles/swift/templates/proxy-server.conf.j2 +++ b/ansible/roles/swift/templates/proxy-server.conf.j2 @@ -1,6 +1,6 @@ [DEFAULT] bind_ip = {{ api_interface_address }} -bind_port = {{ swift_proxy_server_port }} +bind_port = {{ swift_proxy_server_listen_port }} log_udp_host = {{ syslog_server }} log_udp_port = {{ syslog_udp_port }}