Skip to content

Commit

Permalink
add node affinity selector
Browse files Browse the repository at this point in the history
  • Loading branch information
Misfits09 committed Sep 4, 2024
1 parent 12d94c8 commit 739c1ff
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile.fifteen
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ALLOWED_CRDS := "ComputeAddress,ComputeForwardingRule,ComputeServiceAttachment,RunService,CloudSchedulerJob,IAMServiceAccount,IAMPolicyMember,IAMPartialPolicy,ComputeRegionNetworkEndpointGroup,ComputeBackendService,ComputeURLMap,ComputeTargetHTTPProxy,DNSRecordSet,PubSubTopic,EventarcTrigger"
OPERATOR_TAG := 1.0.0
OPERATOR_TAG := 2.0.0
IMAGE := eu.gcr.io/birota-cloud/cnrm-operator:${OPERATOR_TAG}

fix-crds:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2525,6 +2525,8 @@ spec:
cnrm.cloud.google.com/component: cnrm-resource-stats-recorder
cnrm.cloud.google.com/system: "true"
spec:
nodeSelector:
pool: default
containers:
- args:
- --prometheus-scrape-endpoint=:48797
Expand Down Expand Up @@ -2588,6 +2590,8 @@ spec:
cnrm.cloud.google.com/component: cnrm-webhook-manager
cnrm.cloud.google.com/system: "true"
spec:
nodeSelector:
pool: default
containers:
- command:
- /configconnector/webhook
Expand Down Expand Up @@ -2652,6 +2656,8 @@ spec:
cnrm.cloud.google.com/component: cnrm-controller-manager
cnrm.cloud.google.com/system: "true"
spec:
nodeSelector:
pool: default
containers:
- args:
- --prometheus-scrape-endpoint=:8888
Expand Down Expand Up @@ -2710,6 +2716,8 @@ spec:
cnrm.cloud.google.com/component: cnrm-deletiondefender
cnrm.cloud.google.com/system: "true"
spec:
nodeSelector:
pool: default
containers:
- command:
- /configconnector/deletiondefender
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -426,9 +426,7 @@ func setVaultWatcherContainer(object *manifest.Object) (*manifest.Object, error)
"pool": "default",
}

if err := unstructured.SetNestedMap(u.Object, templateSpec, "spec", "template", "spec"); err != nil {
return nil, fmt.Errorf("error setting the template spec for StatefulSet %v: %v", u.GetName(), err)
}
u.Object["spec"].(map[string]interface{})["template"].(map[string]interface{})["spec"] = templateSpec

return manifest.NewObject(u)
}
Expand Down

0 comments on commit 739c1ff

Please sign in to comment.