From cbd2842dbcd72a696aa0a4677365dd5e7db6f691 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Sun, 11 Jul 2021 12:37:10 +0900 Subject: [PATCH] Allow customizing policy rules for Placement Api Depends-on: https://review.opendev.org/800328 Change-Id: I3ec4703f61fbfd1133d28aa327b7f2374670b613 --- deployment/placement/placement-api-container-puppet.yaml | 7 +++++++ .../notes/placement-policies-db2704ea63d0bdad.yaml | 4 ++++ 2 files changed, 11 insertions(+) create mode 100644 releasenotes/notes/placement-policies-db2704ea63d0bdad.yaml diff --git a/deployment/placement/placement-api-container-puppet.yaml b/deployment/placement/placement-api-container-puppet.yaml index c6d9219090..44b13244d4 100644 --- a/deployment/placement/placement-api-container-puppet.yaml +++ b/deployment/placement/placement-api-container-puppet.yaml @@ -80,6 +80,12 @@ parameters: default: false description: Set to True to enable debugging Placement services. type: boolean + PlacementPolicies: + description: | + A hash of policies to configure for Placement API. + e.g. { nova-context_is_admin: { key: context_is_admin, value: 'role:admin' } } + default: {} + type: json conditions: placement_workers_set: @@ -142,6 +148,7 @@ outputs: - {get_param: PlacementDebug} - true - {get_param: Debug} + placement::policy::policies: {get_param: PlacementPolicies} placement::wsgi::apache::api_port: '8778' placement::wsgi::apache::ssl: {get_param: EnableInternalTLS} # NOTE: bind IP is found in hiera replacing the network name with the local node IP diff --git a/releasenotes/notes/placement-policies-db2704ea63d0bdad.yaml b/releasenotes/notes/placement-policies-db2704ea63d0bdad.yaml new file mode 100644 index 0000000000..51f030597d --- /dev/null +++ b/releasenotes/notes/placement-policies-db2704ea63d0bdad.yaml @@ -0,0 +1,4 @@ +--- +features: + - | + The new ``PlacementPolicies`` parameter has been added.