inspector: Prepare to use ironic-inspector user by default

Currently even ironic-inspector services use the ironic keystone user
though the ironic-inspector keystone user is created. This adds
a warning message to make users aware of the future change to use
the own service user.

Change-Id: I62b7cf88496a811f4068244d7a3fb563a53aa1d6
This commit is contained in:
Takashi Kajinami 2023-12-18 01:45:23 +09:00
parent 588fe70ddf
commit 2eaa4e1aa0
5 changed files with 27 additions and 0 deletions

View File

@ -237,6 +237,10 @@ class ironic::inspector::authtoken(
include ironic::deps
if $username == 'ironic' {
warning('The default username will be changed to ironic-inspector in a future release')
}
keystone::resource::authtoken {
'ironic_inspector_config':
* => $params;

View File

@ -76,6 +76,10 @@ class ironic::inspector::ironic (
$retry_interval = $facts['os_service_default'],
) {
if $username == 'ironic' {
warning('The default username will be changed to ironic-inspector in a future release')
}
if is_service_default($system_scope) {
$project_name_real = $project_name
$project_domain_name_real = $project_domain_name

View File

@ -68,6 +68,10 @@ class ironic::inspector::service_catalog (
include ironic::deps
if $username == 'ironic' {
warning('The default username will be changed to ironic-inspector in a future release')
}
if is_service_default($system_scope) {
$project_name_real = $project_name
$project_domain_name_real = $project_domain_name

View File

@ -78,6 +78,10 @@ class ironic::inspector::swift (
$delete_after = $facts['os_service_default'],
) {
if $username == 'ironic' {
warning('The default username will be changed to ironic-inspector in a future release')
}
if is_service_default($system_scope) {
$project_name_real = $project_name
$project_domain_name_real = $project_domain_name

View File

@ -0,0 +1,11 @@
---
upgrade:
- |
Default value of the username parameters in the following classes will be
changed from ``ironic`` to ``ironic-inspector`` in a future release. Set
the username parameters explicitly to keep using the ``ironic`` user.
- ``ironic::inspector::authtoken``
- ``ironic::inspector::ironic``
- ``ironic::inspector::service_catalog``
- ``ironic::inspector::swift``