Browse Source

Merge "Add the ability to offload amphora logs" into stable/ussuri

changes/07/734907/1
Zuul 4 weeks ago
committed by Gerrit Code Review
parent
commit
65a3a9f210
3 changed files with 77 additions and 18 deletions
  1. +7
    -0
      deployment/octavia/octavia-deployment-config.j2.yaml
  2. +66
    -18
      deployment/octavia/octavia-health-manager-container-puppet.yaml
  3. +4
    -0
      releasenotes/notes/octavia-log-offload-d1617e767f688da1.yaml

+ 7
- 0
deployment/octavia/octavia-deployment-config.j2.yaml View File

@@ -185,6 +185,12 @@ parameters:
description: CLI tool used to manage containers.
constraints:
- allowed_values: ['docker', 'podman']
OctaviaLogOffload:
default: false
description: When true, log messages from the amphora will be forwarded
to the administrative log endponts and will be stored with
the controller logs.
type: boolean

conditions:
octavia_raw_image_check:
@@ -251,6 +257,7 @@ resources:
octavia_local_tmpdir: "{{playbook_dir}}/octavia-ansible/local_dir"
octavia_group_vars_dir: "{{playbook_dir}}/octavia-ansible/group_vars"
container_cli: { get_param: ContainerCli }
enable_log_offloading: { get_param: OctaviaLogOffload }

outputs:
role_data:


+ 66
- 18
deployment/octavia/octavia-health-manager-container-puppet.yaml View File

@@ -10,6 +10,9 @@ parameters:
ContainerOctaviaConfigImage:
description: The container image to use for the octavia config_volume
type: string
ContainerOctaviaRsyslogImage:
description: The container image to use for the rsyslog-sidecar
type: string
OctaviaHealthManagerLoggingSource:
type: json
default:
@@ -54,6 +57,16 @@ parameters:
description: Name of the octavia management network interface using
for communication between octavia worker/health-manager
with the amphora machine.
OctaviaLogOffload:
default: false
description: When true, log messages from the amphora will be forwarded
to the administrative log endponts and will be stored with
the controller logs.
type: boolean

conditions:

log_offload_enabled: {equals: [{get_param: OctaviaLogOffload}, true]}

resources:

@@ -83,6 +96,10 @@ outputs:
proto: udp
dport: 5555
iniface: {get_param: OctaviaMgmtPortDevName}
'210 octavia lb-mgmt-net offload rsyslog':
proto: udp
dport: 514
iniface: {get_param: OctaviaMgmtPortDevName}
monitoring_subscription: {get_param: MonitoringSubscriptionOctaviaHealthManager}
config_settings:
map_merge:
@@ -114,6 +131,17 @@ outputs:
- path: /var/log/octavia
owner: octavia:octavia
recurse: true
/var/lib/kolla/config_files/octavia_rsyslog.json:
command: /usr/sbin/rsyslogd -n
config_files:
- source: "/var/lib/kolla/config_files/src/*"
dest: "/"
merge: true
preserve_properties: true
permissions:
- path: /var/log/octavia
owner: octavia:octavia
recurse: true
docker_config:
step_2:
octavia_health_manager_init_dirs:
@@ -130,24 +158,44 @@ outputs:
- /var/lib/config-data/puppet-generated/octavia/etc/octavia:/etc/octavia/:z
command: ['/bin/bash', '-c', 'mkdir -p /etc/octavia/conf.d/octavia-health-manager; chown -R octavia:octavia /etc/octavia/conf.d/octavia-health-manager']
step_5:
octavia_health_manager:
start_order: 2
stop_grace_period: 300
image: *octavia_health_manager_image
net: host
privileged: false
restart: always
healthcheck:
test: /openstack/healthcheck
volumes:
list_concat:
- {get_attr: [ContainersCommon, volumes]}
-
- /var/lib/kolla/config_files/octavia_health_manager.json:/var/lib/kolla/config_files/config.json:ro
- /var/lib/config-data/puppet-generated/octavia:/var/lib/kolla/config_files/src:ro
- /var/log/containers/octavia:/var/log/octavia:z
environment:
KOLLA_CONFIG_STRATEGY: COPY_ALWAYS
map_merge:
- octavia_health_manager:
start_order: 2
stop_grace_period: 300
image: *octavia_health_manager_image
net: host
privileged: false
restart: always
healthcheck:
test: /openstack/healthcheck
volumes:
list_concat:
- {get_attr: [ContainersCommon, volumes]}
-
- /var/lib/kolla/config_files/octavia_health_manager.json:/var/lib/kolla/config_files/config.json:ro
- /var/lib/config-data/puppet-generated/octavia:/var/lib/kolla/config_files/src:ro
- /var/log/containers/octavia:/var/log/octavia:z
environment:
KOLLA_CONFIG_STRATEGY: COPY_ALWAYS
- if:
- log_offload_enabled
- octavia_rsyslog:
start_order: 2
image: {get_param: ContainerOctaviaRsyslogImage}
net: host
privileged: false
restart: always
volumes:
list_concat:
- {get_attr: [ContainersCommon, volumes]}
-
- /var/lib/kolla/config_files/octavia_rsyslog.json:/var/lib/kolla/config_files/config.json:ro
- /var/lib/config-data/puppet-generated/octavia:/var/lib/kolla/config_files/src:ro
- /var/log/containers/octavia:/var/log/octavia:z
environment:
KOLLA_CONFIG_STRATEGY: COPY_ALWAYS
- {}

host_prep_tasks:
- name: create persistent directories
file:


+ 4
- 0
releasenotes/notes/octavia-log-offload-d1617e767f688da1.yaml View File

@@ -0,0 +1,4 @@
---
features:
- |
Adds the "OctaviaLogOffload" setting to enable amphora log offloading.

Loading…
Cancel
Save