Skip to content

Commit 49c8f0c

Browse files
authored
fix: Added error check while writing the base NNC to the cluster
1 parent 73dacc2 commit 49c8f0c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

cns/service/main.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1304,7 +1304,9 @@ func InitializeCRDState(ctx context.Context, httpRestService cns.HTTPService, cn
13041304
// Create Node Network Config CRD and update the Home Az field with the cache value from the HomeAz Monitor
13051305
nnc = createBaseNNC(node)
13061306
}
1307-
directcli.Create(ctx, &nnc)
1307+
if err := directcli.Create(ctx, &nnc); err != nil {
1308+
return errors.Wrap(err, "failed to create base NNC")
1309+
}
13081310

13091311
logger.Printf("Reconciling initial CNS state")
13101312
// apiserver nnc might not be registered or api server might be down and crashloop backof puts us outside of 5-10 minutes we have for

0 commit comments

Comments
 (0)