Closed bells17 closed 2 years ago
@zoetrope Accurate only sets the labels and annotations that are explicitly permitted in the configuration file. So, admins have full control over what a tenant user can do.
@bells17 @zoetrope One thing that I haven't determined is that whether we should have a different set of label/annotation keys for this feature than the keys for propagation.
What do you think?
I understand.
I prefer a simple configuration. I think we should not have the different set.
I agree with @zoetrope.
By the way, should we prioritize SubNamespace labels/annotations over parental Namespace labels/annotations if there have the same labels/annotations key?
OK, let's go with the current proposal.
@bells17
By the way, should we prioritize SubNamespace labels/annotations over parental Namespace labels/annotations if there have the same labels/annotations key?
Definitely not. And even if they would conflict, the parent Namespace labels/annotations win because they are propagated later on.
Thank you @ymmt2005 @zoetrope . I've corrected the points you commented on. Would you review this PR again?
@bells17 I'm curious what happens when I set the same key for labelKeys and subNamespaceLabelKeys.
@zoetrope
I'm curious what happens when I set the same key for labelKeys and subNamespaceLabelKeys.
I implemented so that SubNamespace spec.labels/spec.annotations
values are preferred more than parent namespace labels/annotations
values because I think a case of using SubNamespace spec.labels/spec.annotations
instead of parent namespace labels/annotations
is a rare case.
@ymmt2005 @zoetrope The following points have been updated:
spec.labels/spec.annotations
is now propagated to descendants namespaces.--labels
and --annotations
options to the kubectl-accurate sub create
command.Would you review these points?
Also, could you update this part of the user manual for this new feature? https://cybozu-go.github.io/accurate/subnamespaces.html#creating-a-sub-namespace
I've already updated the user manual, but should I need to make additional updates? https://github.com/cybozu-go/accurate/pull/19/files#diff-b394f5d0e85c3cd9c802a88109196f87c4f5047d04b50c0c557476474460adc4R88-R118
@bells17
I've already updated the user manual, but should I need to make additional updates?
My bad. I overlooked that. It's enough, thank you.
Please validate the labels and annotations in SubNamespace spec field.
added.
@ymmt2005 (cc: @zoetrope) Thank you. I fixed points that are pointed on.
7