Cleanup of external openstack cloud config (#9899)

* redorder options and remove use-octavia

* lowercase true/false
pull/10063/head
John Adams 2023-05-10 06:41:02 -04:00 committed by GitHub
parent 4313c13656
commit 9a72de54de
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 45 additions and 46 deletions

View File

@ -92,18 +92,18 @@ The new cloud provider is configured to have Octavia by default in Kubespray.
- Available variables for configuring lbaas:
```yaml
external_openstack_lbaas_create_monitor: false
external_openstack_lbaas_monitor_delay: "1m"
external_openstack_lbaas_monitor_timeout: "30s"
external_openstack_lbaas_monitor_max_retries: "3"
external_openstack_lbaas_provider: octavia
external_openstack_lbaas_use_octavia: false
external_openstack_lbaas_network_id: "Neutron network ID to create LBaaS VIP"
external_openstack_lbaas_subnet_id: "Neutron subnet ID to create LBaaS VIP"
external_openstack_lbaas_enabled: true
external_openstack_lbaas_floating_network_id: "Neutron network ID to get floating IP from"
external_openstack_lbaas_floating_subnet_id: "Neutron subnet ID to get floating IP from"
external_openstack_lbaas_method: "ROUND_ROBIN"
external_openstack_lbaas_method: ROUND_ROBIN
external_openstack_lbaas_provider: amphora
external_openstack_lbaas_subnet_id: "Neutron subnet ID to create LBaaS VIP"
external_openstack_lbaas_network_id: "Neutron network ID to create LBaaS VIP"
external_openstack_lbaas_manage_security_groups: false
external_openstack_lbaas_create_monitor: false
external_openstack_lbaas_monitor_delay: 5
external_openstack_lbaas_monitor_max_retries: 1
external_openstack_lbaas_monitor_timeout: 3
external_openstack_lbaas_internal_lb: false
```

View File

@ -16,17 +16,18 @@
# openstack_lbaas_monitor_max_retries: "3"
## Values for the external OpenStack Cloud Controller
# external_openstack_lbaas_network_id: "Neutron network ID to create LBaaS VIP"
# external_openstack_lbaas_subnet_id: "Neutron subnet ID to create LBaaS VIP"
# external_openstack_lbaas_enabled: true
# external_openstack_lbaas_floating_network_id: "Neutron network ID to get floating IP from"
# external_openstack_lbaas_floating_subnet_id: "Neutron subnet ID to get floating IP from"
# external_openstack_lbaas_method: "ROUND_ROBIN"
# external_openstack_lbaas_provider: "octavia"
# external_openstack_lbaas_create_monitor: false
# external_openstack_lbaas_monitor_delay: "1m"
# external_openstack_lbaas_monitor_timeout: "30s"
# external_openstack_lbaas_monitor_max_retries: "3"
# external_openstack_lbaas_method: ROUND_ROBIN
# external_openstack_lbaas_provider: amphora
# external_openstack_lbaas_subnet_id: "Neutron subnet ID to create LBaaS VIP"
# external_openstack_lbaas_network_id: "Neutron network ID to create LBaaS VIP"
# external_openstack_lbaas_manage_security_groups: false
# external_openstack_lbaas_create_monitor: false
# external_openstack_lbaas_monitor_delay: 5
# external_openstack_lbaas_monitor_max_retries: 1
# external_openstack_lbaas_monitor_timeout: 3
# external_openstack_lbaas_internal_lb: false
# external_openstack_network_ipv6_disabled: false
# external_openstack_network_internal_networks: []

View File

@ -30,40 +30,45 @@ ca-file="{{ kube_config_dir }}/external-openstack-cacert.pem"
{% endif %}
[LoadBalancer]
create-monitor={{ external_openstack_lbaas_create_monitor }}
monitor-delay={{ external_openstack_lbaas_monitor_delay }}
monitor-timeout={{ external_openstack_lbaas_monitor_timeout }}
monitor-max-retries={{ external_openstack_lbaas_monitor_max_retries }}
{% if external_openstack_lbaas_method is defined %}
lb-method={{ external_openstack_lbaas_method }}
{% endif %}
{% if external_openstack_lbaas_network_id is defined %}
network-id={{ external_openstack_lbaas_network_id }}
{% endif %}
{% if external_openstack_lbaas_subnet_id is defined %}
subnet-id={{ external_openstack_lbaas_subnet_id }}
{% endif %}
enabled={{ external_openstack_lbaas_enabled | string | lower }}
{% if external_openstack_lbaas_floating_network_id is defined %}
floating-network-id={{ external_openstack_lbaas_floating_network_id }}
{% endif %}
{% if external_openstack_lbaas_floating_subnet_id is defined %}
floating-subnet-id={{ external_openstack_lbaas_floating_subnet_id }}
{% endif %}
{% if external_openstack_lbaas_method is defined %}
lb-method={{ external_openstack_lbaas_method }}
{% endif %}
{% if external_openstack_lbaas_provider is defined %}
lb-provider={{ external_openstack_lbaas_provider }}
{% endif %}
{% if external_openstack_lbaas_subnet_id is defined %}
subnet-id={{ external_openstack_lbaas_subnet_id }}
{% endif %}
{% if external_openstack_lbaas_network_id is defined %}
network-id={{ external_openstack_lbaas_network_id }}
{% endif %}
{% if external_openstack_lbaas_manage_security_groups is defined %}
manage-security-groups={{ external_openstack_lbaas_manage_security_groups }}
{% endif %}
{% if external_openstack_lbaas_create_monitor is defined %}
create-monitor={{ external_openstack_lbaas_create_monitor }}
{% endif %}
{% if external_openstack_lbaas_monitor_delay is defined %}
monitor-delay={{ external_openstack_lbaas_monitor_delay }}
{% endif %}
{% if external_openstack_lbaas_monitor_max_retries is defined %}
monitor-max-retries={{ external_openstack_lbaas_monitor_max_retries }}
{% endif %}
{% if external_openstack_lbaas_monitor_timeout is defined %}
monitor-timeout={{ external_openstack_lbaas_monitor_timeout }}
{% endif %}
{% if external_openstack_lbaas_internal_lb is defined %}
internal-lb={{ external_openstack_lbaas_internal_lb }}
{% endif %}
{% if external_openstack_lbaas_provider is defined %}
lb-provider={{ external_openstack_lbaas_provider }}
use-octavia={{ external_openstack_lbaas_use_octavia }}
{% else %}
lb-provider=octavia
use-octavia=true
{% endif %}
{% if external_openstack_enable_ingress_hostname is defined %}
enable-ingress-hostname={{ external_openstack_enable_ingress_hostname | bool }}
enable-ingress-hostname={{ external_openstack_enable_ingress_hostname | string | lower }}
{% endif %}
{% if external_openstack_ingress_hostname_suffix is defined %}
ingress-hostname-suffix={{ external_openstack_ingress_hostname_suffix | string | lower }}

View File

@ -443,15 +443,8 @@ openstack_lbaas_monitor_max_retries: "3"
openstack_cacert: "{{ lookup('env','OS_CACERT') }}"
# Default values for the external OpenStack Cloud Controller
external_openstack_enable_ingress_hostname: false
external_openstack_ingress_hostname_suffix: "nip.io"
external_openstack_max_shared_lb: 2
external_openstack_lbaas_create_monitor: false
external_openstack_lbaas_monitor_delay: "1m"
external_openstack_lbaas_monitor_timeout: "30s"
external_openstack_lbaas_monitor_max_retries: "3"
external_openstack_lbaas_enabled: true
external_openstack_network_ipv6_disabled: false
external_openstack_lbaas_use_octavia: false
external_openstack_network_internal_networks: []
external_openstack_network_public_networks: []