Skip to content

Commit

Permalink
add release old tag
Browse files Browse the repository at this point in the history
  • Loading branch information
bearslyricattack committed Sep 9, 2024
1 parent bfa46b7 commit ff18f75
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions controllers/devbox/api/v1alpha1/devboxrelease_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ const (
// +kubebuilder:printcolumn:name="DevboxName",type="string",JSONPath=".spec.devboxName"
// +kubebuilder:printcolumn:name="NewTag",type="string",JSONPath=".spec.newTag"
// +kubebuilder:printcolumn:name="Phase",type="string",JSONPath=".status.phase"
// +kubebuilder:printcolumn:name="OriginalImage",type="string",JSONPath=".status.originalImage"

// DevBoxReleaseStatus defines the observed state of DevBoxRelease
type DevBoxReleaseStatus struct {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func (r *DevBoxReleaseReconciler) CreateReleaseTag(ctx context.Context, devboxRe
return err
}
logger.Info("Tagging image", "host", hostName, "image", imageName, "oldTag", oldTag, "newTag", devboxRelease.Spec.NewTag)
devboxRelease.Status.OriginalImage = imageName + oldTag
devboxRelease.Status.OriginalImage = imageName + ":" + oldTag
if err = r.Status().Update(ctx, devboxRelease); err != nil {
logger.Error(err, "Failed to update status", "devbox", devboxRelease.Spec.DevboxName, "newTag", devboxRelease.Spec.NewTag)
return err
Expand Down

0 comments on commit ff18f75

Please sign in to comment.