Telegraf container configs don't sync deletes in host:/etc/kolla/telegraf with container:/etc/telegraf/telegraf.d/

Bug #2053230 reported by Martin Ananda Boeker
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
kolla-ansible
Confirmed
Medium
Unassigned

Bug Description

Env: 2023.1

The telegraf container config has this mapping:

"/etc/kolla/telegraf/:/var/lib/kolla/config_files/:ro"

If you have a custom configuration in /etc/kolla/telegraf/config/custom.conf and you edit it, then you start up the container, it does this:

+ sudo -E kolla_set_configs
INFO:__main__:Loading config file at /var/lib/kolla/config_files/config.json
INFO:__main__:Validating config file
INFO:__main__:Kolla config strategy set to: COPY_ALWAYS
INFO:__main__:Copying service configuration files
INFO:__main__:Deleting /etc/telegraf/telegraf.conf
INFO:__main__:Copying /var/lib/kolla/config_files/telegraf.conf to /etc/telegraf/telegraf.conf
INFO:__main__:Setting permission for /etc/telegraf/telegraf.conf
INFO:__main__:Deleting /etc/telegraf/telegraf.d/custom.conf
INFO:__main__:Copying /var/lib/kolla/config_files/config/custom.conf to /etc/telegraf/telegraf.d/custom.conf
INFO:__main__:Setting permission for /etc/telegraf/telegraf.d/custom.conf
INFO:__main__:Writing out command to execute
INFO:__main__:Setting permission for /var/log/kolla/telegraf

That's great. However, if you delete /etc/kolla/telegraf/custom.conf, it does not get removed from /etc/telegraf/telegraf.d/custom.conf inside the container when you restart.

summary: - Telegraf container configs don't sync deletes with /etc/kolla/telegraf
+ Telegraf container configs don't sync deletes in
+ host:/etc/kolla/telegraf with container:/etc/telegraf/telegraf.d/
Revision history for this message
Will Szumski (willjs) wrote :

I've moved this one to kolla-ansible. We have seen this kind of bug with a few other services where old config is left inside the container e.g https://github.com/openstack/kolla-ansible/commit/e7870e9df9e416b1b342ad6264bb66378fe62b3f. If we copy the directory with merge set to false this may fix the issue.

affects: kayobe → kolla-ansible
Changed in kolla-ansible:
status: New → Confirmed
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.