placement/etc/placement/config-generator.conf
Matt Riedemann 9ece3d35ab Deprecate [placement]/policy_file config option
The [placement]/policy_file option was necessary when placement
was in nova since nova uses the standard [oslo_policy]/policy_file
option for defining custom policy rules. Now that placement is
extracted (+1 release) we can deprecate the placement-specific
option and use the standard [oslo_policy]/policy_file option as well.

The tricky thing with this is both options define a default value
but those values are different, and neither need to exist or can
exist but be empty and we'll use policy defaults from code. So some
logic is necessary for detecting which option we should pass to the
oslo.policy Enforcer object. We prefer to use [oslo_policy]/policy_file
if it exists but will fallback to use [placement]/policy_file for
backward compatibility. We also check for a couple of edge cases to
try and detect misconfiguration and usage of the deprecated option.

The config generation docs are updated to include the [oslo_policy]
options as well as registering the options from that library for
runtime code.

Change-Id: Ifb14d2c14b17fc5bcdf7d124744ac2e1b58fd063
Story: #2005171
Task: #29913
2019-09-12 18:18:49 -04:00

12 lines
398 B
Plaintext

[DEFAULT]
output_file = etc/placement/placement.conf.sample
wrap_width = 80
namespace = placement.conf
namespace = keystonemiddleware.auth_token
namespace = oslo.log
namespace = oslo.middleware.cors
namespace = oslo.policy
namespace = osprofiler
# FIXME(mriedem): There are likely other missing 3rd party oslo library
# options that should show up in the placement.conf docs, like oslo.concurrency