-
Notifications
You must be signed in to change notification settings - Fork 45
Rename labels from sigs.k8s.io to machine.openshift.io #161
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
Rename labels from sigs.k8s.io to machine.openshift.io #161
Conversation
this will need a counter part PR on the installer for the machine manifests. Can you add openshift/installer#1263 to the description for reference |
|
spec: | ||
replicas: 2 | ||
selector: | ||
matchLabels: | ||
sigs.k8s.io/cluster-api-machineset: test-master | ||
sigs.k8s.io/cluster-api-cluster: tb-asg-35 | ||
machine.openshift.io/cluster-api-machineset: test-master |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for consistency, should this be machine-api-machineset
and same for all cluster-api references?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't have any opinion on that, maybe some others can chime in here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with @ingvagabund I guess. It doesn't really matter. There's an argument to be made for keeping it exactly like upstream except for the domain prefix though. If I were picking anything I wanted, I'd call it machine.openshift.io/machineset
I think. I don't know... maybe this isn't helpful at all.
test/e2e/provider_expectations.go
Outdated
@@ -140,7 +140,7 @@ func (tc *testConfig) ExpectNewNodeWhenDeletingMachine() error { | |||
var triagedWorkerNode corev1.Node | |||
MachineLoop: | |||
for _, m := range machineList.Items { | |||
if m.Labels["sigs.k8s.io/cluster-api-machine-role"] == "worker" { | |||
if m.Labels["machine.openshift.io/cluster-api-machine-role"] == "worker" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this will never pass the tests unless you make it backward compatible with the installer labels
test/e2e/provider_expectations.go
Outdated
@@ -217,7 +217,7 @@ func (tc *testConfig) ExpectNodeToBeDrainedBeforeDeletingMachine() error { | |||
} | |||
for _, machineItem := range machineList.Items { | |||
// empty or non-worker role skipped | |||
if machineItem.Labels["sigs.k8s.io/cluster-api-machine-role"] == "worker" { | |||
if machineItem.Labels["machine.openshift.io/cluster-api-machine-role"] == "worker" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this will never pass the tests unless you make it backward compatible with the installer labels
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
@@ -140,7 +140,7 @@ func (tc *testConfig) ExpectNewNodeWhenDeletingMachine() error { | |||
var triagedWorkerNode corev1.Node | |||
MachineLoop: | |||
for _, m := range machineList.Items { | |||
if m.Labels["sigs.k8s.io/cluster-api-machine-role"] == "worker" { | |||
if m.Labels["machine.openshift.io/cluster-api-machine-role"] == "worker" || m.Labels["sigs.k8s.io/cluster-api-machine-role"] == "worker" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I won't block this PR on this, but we should really be using the already defined constants here.
/retest |
ClusterIDLabel = "sigs.k8s.io/cluster-api-cluster" | ||
MachineRoleLabel = "sigs.k8s.io/cluster-api-machine-role" | ||
MachineTypeLabel = "sigs.k8s.io/cluster-api-machine-type" | ||
ClusterIDLabel = "machine.openshift.io/cluster-api-cluster" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@spangenberg this will never pass the test as it would break the installer unless you make it backward compatible since ClusterIDLabel
it's used by getClusterID
which is used to get aws instances
@spangenberg Please check the CI logs before rerunning tests. Nodes are not coming up because of #161 (comment)
Once you fix and merge this PR. It will unblock integration tests here https://github.com/openshift/machine-api-operator/pull/213/files#diff-17c17f0cec2da748cc69098a4166b579 Then we need to make sure to sync openshift/origin#22090 and we can merge openshift/installer#1263 and eventually remove the deprecated labels from the other repos |
d2fc412
to
de09fc6
Compare
/retest |
2 similar comments
/retest |
/retest |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ingvagabund The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/test e2e-aws |
/cc bison