26a55415ab
As a followup to Id99948aec64656a0532afc68e146f0610bff1378, adding auto detection to haproxy_amphora.user_group haproxy is capable[1] handling a list of configuration files. This patch leverages that capability by simply providing haproxy with an additional configuration file, which is baked in the amphora image via a diskimage-builder element. The above-mentioned element will specify the following values for user group: Ubuntu: 'nogroup' RHEL/CentOS/Fedora: 'haproxy' The amphora-agent will parse and remove any user_group configuration provided by Octavia controller worker. This is in order to maintain amphora-agent backward compatibility to old Octavia workers, who still provide user_group to the amphora-agent. Octavia Workers that include this patch will no longer provide user_group configuration to the amphora-agent. [1] https://cbonte.github.io/haproxy-dconv/1.7/management.html#3 Related-Bug #1548070 Change-Id: Ia8fede9d7da4709a48661d1fc595a16d04fcbfa9
19 lines
399 B
Bash
Executable File
19 lines
399 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
|
|
set -x
|
|
fi
|
|
set -eu
|
|
set -o pipefail
|
|
|
|
pip install -U -c /opt/upper-constraints.txt /opt/amphora-agent
|
|
|
|
# Accommodate centos default install location
|
|
ln -s /bin/amphora-agent /usr/local/bin/amphora-agent || true
|
|
|
|
mkdir /etc/octavia
|
|
# we assume certs, etc will come in through the config drive
|
|
mkdir /etc/octavia/certs
|
|
mkdir -p /var/lib/octavia
|
|
|