-
Notifications
You must be signed in to change notification settings - Fork 67
Description
Description
This PR: #1530 introduced a feature where, stopped workspaces are backed up periodically.
To use this feature, the backup cron job must be enabled in the DWOC:
kind: DevWorkspaceOperatorConfig
metadata:
name: devworkspace-operator-config
namespace: openshift-operators
apiVersion: controller.devfile.io/v1alpha1
config:
workspace:
backupCronJob:
enable: true
registry:
path: <internal openshift registry url>
schedule: '* * * * *'
The DWOC's status.lastBackupTime field will display the last time the backups jobs have been attempted for non-ephemeral workspaces in the cluster.
However, with the current implementation, it is not possible to distinguish whether or not old devworkspaces have successfully been backed up. In the backup job, there are multiple reasons why a back up might have been unsuccessful (for example, the image registry could be down).
It would be great if we can set annotations to successfully backed up workspaces, in order to determine which workspaces have been backed up, and which workspaces should be backed up in the next cron job. A successful backup means that the backup job pod has successfully built and pushed the image to an image registry.
See https://github.com/devfile/devworkspace-operator/pull/1530/changes#r2576240030 for context.
When the backup cron job determine which workspaces to back up (for example here), the job can potentially use this new annotation to help determine that.