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

✨ Set install namespace of addonTemplate from config #417

Conversation

qiujian16
Copy link
Member

Summary

Related issue(s)

Fixes #

@qiujian16
Copy link
Member Author

qiujian16 commented Apr 11, 2024

/hold
/assign @zhujian7

still need e2e test.

Copy link

codecov bot commented Apr 11, 2024

Codecov Report

Attention: Patch coverage is 80.00000% with 21 lines in your changes are missing coverage. Please review.

Project coverage is 62.42%. Comparing base (bcbe4d2) to head (6b893cb).
Report is 24 commits behind head on main.

Files Patch % Lines
pkg/addon/templateagent/decorator.go 80.51% 9 Missing and 6 partials ⚠️
pkg/addon/templateagent/template_agent.go 71.42% 2 Missing and 2 partials ⚠️
pkg/addon/templateagent/values.go 83.33% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #417      +/-   ##
==========================================
+ Coverage   61.54%   62.42%   +0.87%     
==========================================
  Files         133      133              
  Lines       14078    11390    -2688     
==========================================
- Hits         8665     7110    -1555     
+ Misses       4664     3518    -1146     
- Partials      749      762      +13     
Flag Coverage Δ
unit 62.42% <80.00%> (+0.87%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@qiujian16 qiujian16 force-pushed the install-ns-template branch from 59b2793 to a4615c5 Compare April 15, 2024 13:19
Copy link
Contributor

openshift-ci bot commented Apr 15, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: qiujian16

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@qiujian16 qiujian16 force-pushed the install-ns-template branch 3 times, most recently from 9737759 to 457e6ec Compare April 18, 2024 01:08
Signed-off-by: Jian Qiu <jqiu@redhat.com>
@qiujian16 qiujian16 force-pushed the install-ns-template branch 4 times, most recently from 0fab09f to aca0f0d Compare April 18, 2024 13:32
pkg/addon/templateagent/decorator.go Outdated Show resolved Hide resolved
pkg/addon/templateagent/decorator.go Outdated Show resolved Hide resolved
pkg/addon/templateagent/decorator.go Outdated Show resolved Hide resolved
pkg/addon/templateagent/values.go Outdated Show resolved Hide resolved
@qiujian16 qiujian16 force-pushed the install-ns-template branch 2 times, most recently from 6c43049 to 8856ef6 Compare April 22, 2024 03:02
@@ -60,8 +69,9 @@ func (a *CRDTemplateAgentAddon) getValues(
overrideValues = addonfactory.MergeValues(overrideValues, defaultValues)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
overrideValues = addonfactory.MergeValues(overrideValues, defaultValues)
overrideValues = addonfactory.MergeValues(defaultValues, overrideValues)

Signed-off-by: Jian Qiu <jqiu@redhat.com>
@qiujian16 qiujian16 force-pushed the install-ns-template branch from 8856ef6 to 6b893cb Compare April 22, 2024 04:03
},
},
{
name: "default should not be overridden",
Copy link
Member

@zhujian7 zhujian7 Apr 22, 2024

Choose a reason for hiding this comment

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

nit: default values can not be overridden, there are some descriptions in the tests that are not precise, I can submit another PR to refactor it after this is merged.

@zhujian7
Copy link
Member

/lgtm

@qiujian16
Copy link
Member Author

/unhold

@openshift-merge-bot openshift-merge-bot bot merged commit a7adf5d into open-cluster-management-io:main Apr 22, 2024
14 checks passed
@zhujian7
Copy link
Member

@qiujian16 I suggest that we add a :warning: to the PR title: ✨ ⚠️ Set install namespace of addonTemplate from config, and add some description to the PR summary to state the INSTALL_NAMESPACE is removed, and user can use downward API, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants