-
Notifications
You must be signed in to change notification settings - Fork 23
Restarting container causes fluentd.conf to duplicate config #68
Comments
Oh - looks like the boot script is just appending the custom configs to the file without wiping any previous ones. Perhaps it would make sense to wrap all the custom configs between a custom comment string and wipe it at every boot before appending the new configs? |
if the pod died that should have been a new config. hwo did the container restart without the pod dying? |
I was testing out a config change quickly and restarted the container manually. If you're never worried about the container restarting, then this isn't an issue. |
ah k that makes sense. Its definitely a valid usecase just something I hadnt considered. We should probably make sure that we are building the config file correctly. |
Oh good. I was worried I was being a PITA. I notice that fluentd supports an @include directive. Perhaps we include the custom config and rewrite the file each time? I'm happy to give it a shot if you think it's a decent idea. |
well the includes would need to be conditional which means you just move them from 1 spot to another. Might not be too bad but i wonder if it makes it confusing on what needs to happen for a paritcular config file to be included in the main one. Make sense? |
I guess what I'm suggesting is putting all the dynamic configuration in a different file that we can rebuild each time instead of appending to the |
Alright let me think about this for a day. I have some ideas but I have a ton of prs in flight so want to make sure I get those merged before I start on this. |
@jchauncey Sure thing! Like you mentioned, if a pod dies it would recreate the container, so this is probably a pretty rare edge case, so not that important. Thanks for entertaining the idea. When/if you settle on an implementation direction, let me know. I'd be happy to help out and create a PR. |
This issue was moved to teamhephy/fluentd#7 |
Logs of a deis fluentd container during it's first run:
If I restart the container, the config is duplicated:
I'm not sure what's up yet. Looking into it now. Apologies in advance if this is already known or intentional behavior.
The text was updated successfully, but these errors were encountered: