Skip to content

Commit

Permalink
[daemonset] Make get method public
Browse files Browse the repository at this point in the history
Needed-by: openstack-k8s-operators/ovn-operator#337
Related: OSPRH-7463
(cherry picked from commit 321e10b)
  • Loading branch information
averdagu authored and stuggi committed Sep 6, 2024
1 parent fbb3882 commit e5bbad6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions modules/common/daemonset/daemonset.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func (d *DaemonSet) CreateOrPatch(
}

// update the daemonset object of the daemonset type
d.daemonset, err = getDaemonSetWithName(ctx, h, daemonset.GetName(), daemonset.GetNamespace())
d.daemonset, err = GetDaemonSetWithName(ctx, h, daemonset.GetName(), daemonset.GetNamespace())
if err != nil {
if k8s_errors.IsNotFound(err) {
return ctrl.Result{RequeueAfter: d.timeout}, nil
Expand Down Expand Up @@ -112,7 +112,8 @@ func (d *DaemonSet) GetDaemonSet() appsv1.DaemonSet {
return *d.daemonset
}

func getDaemonSetWithName(
// GetDaemonSetWithName - get the daemonset object with a given name.
func GetDaemonSetWithName(
ctx context.Context,
h *helper.Helper,
name string,
Expand Down

0 comments on commit e5bbad6

Please sign in to comment.