Skip to content

Commit ad1f8cc

Browse files
committed
fixup! Propagate DevWorkspace .spec.started status to an annotation on routings
1 parent 07d2e6f commit ad1f8cc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

controllers/workspace/devworkspace_controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ func (r *DevWorkspaceReconciler) doStop(workspace *dw.DevWorkspace, logger logr.
417417
return false, err
418418
}
419419

420-
// Update DevWorkspaceRouting to have .spec.started=false
420+
// Update DevWorkspaceRouting to have `devworkspace-started` annotation "false"
421421
routing := &v1alpha1.DevWorkspaceRouting{}
422422
routingRef := types.NamespacedName{
423423
Name: common.DevWorkspaceRoutingName(workspace.Status.DevWorkspaceId),

pkg/provision/workspace/routing.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ func getSpecRouting(
154154
if val, ok := workspace.Annotations[constants.DevWorkspaceRestrictedAccessAnnotation]; ok {
155155
annotations = maputils.Append(annotations, constants.DevWorkspaceRestrictedAccessAnnotation, val)
156156
}
157-
annotations[constants.DevWorkspaceStartedStatusAnnotation] = "true"
157+
annotations = maputils.Append(annotations, constants.DevWorkspaceStartedStatusAnnotation, "true")
158158

159159
// copy the annotations for the specific routingClass from the workspace object to the routing
160160
expectedAnnotationPrefix := workspace.Spec.RoutingClass + constants.RoutingAnnotationInfix

0 commit comments

Comments
 (0)