Skip to content

Conversation

@sm43
Copy link
Member

@sm43 sm43 commented Aug 10, 2021

This is always true in case of openshift due to which user would
not able to enable it. so this fixes by removing the defaulting in
Operator CR and adding the field only when user adds it.
By default, the value in configmap is false for kubernetes and will
be changed to true for openshift which user can change if requires.

fixes #372

Signed-off-by: Shivam Mukhade smukhade@redhat.com

Changes

Submitter Checklist

These are the criteria that every PR should meet, please check them off as you
review them:

See the contribution guide for more details.

Release Notes

This is always true in case of openshift due to which user would
not able to enable it. so this fixes by removing the defaulting in
Operator CR and adding the field only when user adds it.
By default, the value in configmap is false for kubernetes and will
be changed to true for openshift which user can change if requires.

Signed-off-by: Shivam Mukhade <smukhade@redhat.com>
@tekton-robot tekton-robot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Aug 10, 2021
@tekton-robot tekton-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Aug 10, 2021
@sm43
Copy link
Member Author

sm43 commented Aug 10, 2021

/cc @vdemeester @nikhil-thomas

@tekton-robot tekton-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 10, 2021
*properties.DisableAffinityAssistant = DefaultDisableAffinityAssistant
// Set `disable-affinity-assistant` to true if not set in CR
// webhook will not set any value but by default in pipelines configmap it will be false
if properties.DisableAffinityAssistant == nil {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so from Operator we can configure DisableAffinityAssistant only for Openshift and not for K8s then in that case can we add comment here https://github.com/tektoncd/operator/blob/main/pkg/apis/operator/v1alpha1/tektonpipeline_types.go#L84 so that it will be more clear

not necessarily in this instead we do it in another PR

WDYT?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@savitaashture it's support on all platform. Only on Openshift the default is different (true instead of false)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep. on kubernetes by default the field will not be set in TektonConfig CR, user can define and alter value.
by default it will be false in configmap.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sm43 but on k8s, if the user set then in the TektonConfig CR, the will be applied to the managed tekton instance right ?

Copy link
Member Author

@sm43 sm43 Aug 11, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes.. user can define the field in k8s and change the value

@savitaashture
Copy link
Contributor

/lgtm

/hold
For others to take look

@tekton-robot tekton-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged. labels Aug 18, 2021
@tekton-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: vdemeester

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@savitaashture
Copy link
Contributor

/hold cancel

@tekton-robot tekton-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 20, 2021
@savitaashture
Copy link
Contributor

/lgtm

@tekton-robot tekton-robot merged commit 890ff32 into tektoncd:main Aug 20, 2021
@sm43 sm43 deleted the fix-affinity-assistant branch October 10, 2021 15:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AffinityAssistant configuration on OpenShift not taken into account

4 participants