Skip to content

Commit 9d2b116

Browse files
committed
Use namespaced registry path for backup
In case user uses internal registry in the OCP the image repository path aligns with OCP namespace and creates a image stream given by the workspace name. Signed-off-by: Ales Raszka <[email protected]>
1 parent 191bec9 commit 9d2b116

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

apis/controller/v1alpha1/devworkspaceoperatorconfig_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ type CleanupCronJobConfig struct {
7474

7575
type RegistryConfig struct {
7676
// A registry where backup images are stored. Images are stored
77-
// in {registry}/backup-${DEVWORKSPACE_NAMESPACE}-${DEVWORKSPACE_NAME}
77+
// in {path}/${DEVWORKSPACE_NAMESPACE}:${DEVWORKSPACE_NAME}
7878
// +kubebuilder:validation:Required
7979
Path string `json:"path,omitempty"`
8080
// AuthSecret is the name of a Kubernetes secret of

project-backup/workspace-recovery.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ set -x
2323
: "${DEVWORKSPACE_NAME:?Missing DEVWORKSPACE_NAME}"
2424
: "${BACKUP_SOURCE_PATH:?Missing BACKUP_SOURCE_PATH}"
2525

26-
BACKUP_IMAGE="${DEVWORKSPACE_BACKUP_REGISTRY}/backup-${DEVWORKSPACE_NAMESPACE}-${DEVWORKSPACE_NAME}:latest"
26+
BACKUP_IMAGE="${DEVWORKSPACE_BACKUP_REGISTRY}/${DEVWORKSPACE_NAMESPACE}:${DEVWORKSPACE_NAME}"
2727

2828
# --- Functions ---
2929
backup() {

0 commit comments

Comments
 (0)