Redis: Switch to the new config file path

The redis.conf file is placed under /etc/redis, instead of /etc, in
CentOS 9. This change completely adapts to that change because current
master no longer supports CentOS 8.

This change also moves the redis-tls.conf to /etc/redis to gather all
config files into the same directory.

Change-Id: I56767cb42a3cbe73242dddad2e6c00876e6ac448
This commit is contained in:
Takashi Kajinami 2022-06-24 00:27:37 +09:00
parent 8cb7c81d20
commit e5ea92a5fb
2 changed files with 7 additions and 14 deletions

View File

@ -99,13 +99,6 @@ outputs:
map_merge:
- {get_attr: [RedisBase, role_data, config_settings]}
- redis::daemonize: false
# NOTE(tkajinam): In CentOS9, the file is placed under /etc/redis.
# Redis resource agent can deal with both of
# the old path and the new path, but the command
# line below for standalone redis does not.
# TODO(tkajinam): Remove this when we drop support for CentOS8.
redis::config_file: '/etc/redis.conf'
redis::config_file_orig: '/etc/redis.conf.puppet'
tripleo::stunnel::foreground: 'yes'
- tripleo::profile::base::database::redis::tls_proxy_bind_ip:
str_replace:
@ -130,8 +123,8 @@ outputs:
# BEGIN DOCKER SETTINGS
puppet_config:
config_volume: 'redis'
# NOTE: we need the exec tag to copy /etc/redis.conf.puppet to
# /etc/redis.conf
# NOTE: we need the exec tag to copy /etc/redis/redis.conf.puppet to
# /etc/redis/redis.conf
# https://github.com/arioch/puppet-redis/commit/1c004143223e660cbd433422ff8194508aab9763
puppet_tags: 'exec'
step_config:
@ -143,7 +136,7 @@ outputs:
config_image: {get_attr: [RoleParametersValue, value, ContainerRedisConfigImage]}
kolla_config:
/var/lib/kolla/config_files/redis.json:
command: /usr/bin/redis-server /etc/redis.conf
command: /usr/bin/redis-server /etc/redis/redis.conf
config_files:
- source: "/var/lib/kolla/config_files/src/*"
dest: "/"

View File

@ -180,8 +180,8 @@ outputs:
tripleo::profile::pacemaker::database::redis::tls_proxy_port: 6379
- if:
- {get_param: EnableInternalTLS}
- redis::extra_config_file: "/etc/redis-tls.conf"
tripleo::profile::pacemaker::database::redis_bundle::extra_config_file: "/etc/redis-tls.conf"
- redis::extra_config_file: "/etc/redis/redis-tls.conf"
tripleo::profile::pacemaker::database::redis_bundle::extra_config_file: "/etc/redis/redis-tls.conf"
tripleo::profile::pacemaker::database::redis_bundle::tls_tunnel_base_port: 6660
tripleo::profile::pacemaker::database::redis_bundle::tls_tunnel_local_name:
if:
@ -192,8 +192,8 @@ outputs:
# BEGIN DOCKER SETTINGS
puppet_config:
config_volume: 'redis'
# NOTE: we need the exec tag to copy /etc/redis.conf.puppet to
# /etc/redis.conf
# NOTE: we need the exec tag to copy /etc/redis/redis.conf.puppet to
# /etc/redis/redis.conf
# https://github.com/arioch/puppet-redis/commit/1c004143223e660cbd433422ff8194508aab9763
puppet_tags: 'exec'
step_config: |