Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix PR buildkite execution #17

Merged
merged 8 commits into from
Nov 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,6 @@ steps:

- key: k8s-operator
label: K8s Operator
if: |
build.env("K8S_NIGHTLY") == "1" ||
build.branch == "main" ||
(build.pull_request.labels includes "k8s/tests") ||
build.tag != null
timeout: 180
notify:
- github_commit_status:
Expand Down
52 changes: 52 additions & 0 deletions src/go/k8s/api/redpanda/v1alpha1/redpanda_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -227,3 +227,55 @@ func (in *Redpanda) OwnerShipRefObj() metav1.OwnerReference {
UID: in.UID,
}
}

// GetMigrationConsoleName returns Console custom resource namespace which will be taken out from
// old reconciler, so that underlying resources could be migrated.
func (in *Redpanda) GetMigrationConsoleName() string {
if in.Spec.Migration == nil {
return ""
}
name := in.Spec.Migration.ConsoleRef.Name
if name == "" {
name = in.Name
}
return name
}

// GetMigrationConsoleNamespace returns Console custom resource name which will be taken out from
// old reconciler, so that underlying resources could be migrated.
func (in *Redpanda) GetMigrationConsoleNamespace() string {
if in.Spec.Migration == nil {
return ""
}
namespace := in.Spec.Migration.ConsoleRef.Namespace
if namespace == "" {
namespace = in.Namespace
}
return namespace
}

// GetMigrationClusterName returns Cluster custom resource namespace which will be taken out from
// old reconciler, so that underlying resources could be migrated.
func (in *Redpanda) GetMigrationClusterName() string {
if in.Spec.Migration == nil {
return ""
}
name := in.Spec.Migration.ClusterRef.Name
if name == "" {
name = in.Name
}
return name
}

// GetMigrationClusterNamespace returns Cluster custom resource name which will be taken out from
// old reconciler, so that underlying resources could be migrated.
func (in *Redpanda) GetMigrationClusterNamespace() string {
if in.Spec.Migration == nil {
return ""
}
namespace := in.Spec.Migration.ClusterRef.Namespace
if namespace == "" {
namespace = in.Namespace
}
return namespace
}
Loading
Loading