From 949261f34259fc7ade9868515008cf8c242b9839 Mon Sep 17 00:00:00 2001 From: Michael Johnson Date: Fri, 16 Mar 2018 11:40:36 -0700 Subject: [PATCH] Add a devstack variable for legacy RBAC This patch adds the OCTAVIA_USE_LEGACY_RBAC variable to our devstack plugin. When set to True it will install the legacy Admin/Owner RBAC policy.json file for the devstack Octavia install. This is useful for tempest testing the neutron-lbaas proxy driver that passes neutron LBaaSv2 API requests through to the Octavia API. Change-Id: I5f112131b9c57e394349f29fa1b675643784b867 --- devstack/plugin.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index dd1afd8f95..ae9ef9d3b8 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -300,6 +300,10 @@ function octavia_configure { iniset $OCTAVIA_CONF certificates ca_private_key ${OCTAVIA_CERTS_DIR}/private/cakey.pem iniset $OCTAVIA_CONF certificates ca_private_key_passphrase foobar + if [[ "$OCTAVIA_USE_LEGACY_RBAC" == "True" ]]; then + cp $OCTAVIA_DIR/etc/policy/admin_or_owner-policy.json $OCTAVIA_CONF_DIR/policy.json + fi + # create dhclient.conf file for dhclient mkdir -m755 -p $OCTAVIA_DHCLIENT_DIR cp $OCTAVIA_DIR/etc/dhcp/dhclient.conf $OCTAVIA_DHCLIENT_CONF