Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make the admin namespace configurable #118

Merged
merged 2 commits into from
May 14, 2020

Conversation

tommasopozzetti
Copy link
Contributor

The config-reloader assumes that the admin namespace in which fluentd configs get defined without validation and/or processing and in which virtual plugins are defined is the kube-system namespace. While this assumption is reasonable in general, there might be instances in which the logging infrastructure is installed in a dedicated namespace and it would be cleaner and more manageable to be able to install virtual plugins and global fluentd configs in that same namespace. Furthermore, it might be the case that the kube-system namespace already contains a number of infrastructural components that would benefit from having fluentd configurations defined using the config-reloader and that would also benefit from all the processing that the config-reloader can offer on those configs, such as the "$labels" macro and so on.

This PR adds the possibility of configuring which is the namespace that is used as an admin namespace through a flag of config-reloader which defaults to kube-system for backwards compatibility. This way, cluster admins which would benefit from defining global fluentd configs and virtual plugins in a specific dedicated namespace can choose to do so.

The config-reloader assumes that the admin namespace in which configs
get defined without validation and/or processing and in which virtual
plugins get defined is the "kube-system" namespace. While this assumption
is reasonable in general, there might be instances in which the logging
infrastructure is installed in a dedicated namespace and it would be
cleaner and more manageable to be able to install virtual plugins and
global fluentd configs in that same namespace. Furthermore, it might
be the case that the kube-system namespace already contains a number
of infrastructural components that would benefit from having fluentd
configurations defined using the config-reloader and that would also
benefit from all the processing that the config-reloader can offer
on those configs, such as the "$labels" macro and so on.

This commit adds the possibility of configuring which is the namespace
that is used as an admin namespace through a flag of config-reloader
which defaults to "kube-system" for backwards compatibility. This way,
if the necessity of a different configuration arises, the config-
reloader can be installed to check for plugins and avoid validations of
configs from a different namespace.

Signed-off-by: Tommaso Pozzetti <tommypozzetti@hotmail.it>
@dimalbaby
Copy link
Contributor

The config-reloader assumes that the admin namespace in which fluentd configs get defined without validation and/or processing and in which virtual plugins are defined is the kube-system namespace. While this assumption is reasonable in general, there might be instances in which the logging infrastructure is installed in a dedicated namespace and it would be cleaner and more manageable to be able to install virtual plugins and global fluentd configs in that same namespace. Furthermore, it might be the case that the kube-system namespace already contains a number of infrastructural components that would benefit from having fluentd configurations defined using the config-reloader and that would also benefit from all the processing that the config-reloader can offer on those configs, such as the "$labels" macro and so on.

This PR adds the possibility of configuring which is the namespace that is used as an admin namespace through a flag of config-reloader which defaults to kube-system for backwards compatibility. This way, cluster admins which would benefit from defining global fluentd configs and virtual plugins in a specific dedicated namespace can choose to do so.

Thanks for the PR. The changes looks good to me.
Can you also consider an update on the doc "A note on the kube-system namespace" ?
cc/@gautam2187

Signed-off-by: Tommaso Pozzetti <tommypozzetti@hotmail.it>
@tommasopozzetti
Copy link
Contributor Author

tommasopozzetti commented May 13, 2020

@dimalbaby Thank you for reviewing. I added a commit with a doc update to include info on the admin namespace.

@dimalbaby
Copy link
Contributor

@tommasopozzetti Thanks

@dimalbaby dimalbaby merged commit 60847e0 into vmware:master May 14, 2020
@tommasopozzetti tommasopozzetti deleted the configure-admin-ns branch May 15, 2020 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants