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

ensureRsyslogConfigMap: Remove ingressConfig param #573

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkg/operator/controller/ingress/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ func (r *reconciler) ensureIngressController(ci *operatorv1.IngressController, d
errs = append(errs, fmt.Errorf("failed to integrate metrics with openshift-monitoring for ingresscontroller %s: %v", ci.Name, err))
}

if _, _, err := r.ensureRsyslogConfigMap(ci, deploymentRef, ingressConfig); err != nil {
if _, _, err := r.ensureRsyslogConfigMap(ci, deploymentRef); err != nil {
errs = append(errs, err)
}

Expand Down
7 changes: 3 additions & 4 deletions pkg/operator/controller/ingress/rsyslog_configmap.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"github.com/google/go-cmp/cmp"
"github.com/google/go-cmp/cmp/cmpopts"

configv1 "github.com/openshift/api/config/v1"
operatorv1 "github.com/openshift/api/operator/v1"
"github.com/openshift/cluster-ingress-operator/pkg/operator/controller"

Expand All @@ -30,8 +29,8 @@ $ModLoad omstdout.so
// ingresscontroller if the access logging is enabled. Returns a Boolean
// indicating whether the configmap exists, the configmap if it does exist, and
// an error value.
func (r *reconciler) ensureRsyslogConfigMap(ic *operatorv1.IngressController, deploymentRef metav1.OwnerReference, ingressConfig *configv1.Ingress) (bool, *corev1.ConfigMap, error) {
wantCM, desired, err := desiredRsyslogConfigMap(ic, deploymentRef, ingressConfig)
func (r *reconciler) ensureRsyslogConfigMap(ic *operatorv1.IngressController, deploymentRef metav1.OwnerReference) (bool, *corev1.ConfigMap, error) {
wantCM, desired, err := desiredRsyslogConfigMap(ic, deploymentRef)
if err != nil {
return false, nil, fmt.Errorf("failed to build configmap: %v", err)
}
Expand Down Expand Up @@ -73,7 +72,7 @@ func (r *reconciler) ensureRsyslogConfigMap(ic *operatorv1.IngressController, de
// desiredRsyslogConfigMap returns the desired rsyslog configmap. Returns a
// Boolean indicating whether a configmap is desired, as well as the configmap
// if one is desired.
func desiredRsyslogConfigMap(ic *operatorv1.IngressController, deploymentRef metav1.OwnerReference, ingressConfig *configv1.Ingress) (bool, *corev1.ConfigMap, error) {
func desiredRsyslogConfigMap(ic *operatorv1.IngressController, deploymentRef metav1.OwnerReference) (bool, *corev1.ConfigMap, error) {
accessLogging := accessLoggingForIngressController(ic)
if accessLogging == nil || accessLogging.Destination.Type != operatorv1.ContainerLoggingDestinationType {
return false, nil, nil
Expand Down