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

Bug 1876440: Cloud init section of common-templates is ignored #6543

Merged
merged 1 commit into from Sep 15, 2020

Conversation

glekner
Copy link
Contributor

@glekner glekner commented Sep 7, 2020

image

@openshift-ci-robot
Copy link
Contributor

@glekner: This pull request references Bugzilla bug 1876440, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.6.0) matches configured target release for branch (4.6.0)
  • bug is in the state NEW, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

In response to this:

Bug 1876440: Cloud init section of common-templates is ignored

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot openshift-ci-robot added bugzilla/severity-high Referenced Bugzilla bug's severity is high for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. component/kubevirt Related to kubevirt-plugin labels Sep 7, 2020
@@ -115,6 +126,40 @@ const osUpdater = ({ id, prevState, dispatch, getState }: UpdateOptions) => {
{ isHidden: asHidden(!isWindows, VMSettingsField.OPERATING_SYSTEM), value: isWindows },
),
);

const relevantOptions = iGetRelevantTemplateSelectors(state, id);
Copy link
Member

Choose a reason for hiding this comment

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

relevant template can change on relevenatOptions, not just os. IMO this needs its own updater and possibly new file called eg commonTemplatesPrefil

Copy link
Member

Choose a reason for hiding this comment

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

as mentioned here https://bugzilla.redhat.com/show_bug.cgi?id=1874074.

We are going to need a generic approach to common template prefill soon.

const [data, isBase64] = CloudInitDataHelper.getUserData(
toShallowJS(iCloudInitVolume)?.cloudInitNoCloud,
);

Copy link
Member

Choose a reason for hiding this comment

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

please take an inspiration from prefill-vm-template-state-update.ts

false,
),
);
dispatch(
Copy link
Member

Choose a reason for hiding this comment

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

you need to take into account cloudinit from other templates.

Copy link
Member

Choose a reason for hiding this comment

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

also please test this with a userTemplate

@@ -97,3 +98,8 @@ export const iGetRelevantTemplates = (
export const iGetRelevantTemplate = (
...args: Parameters<typeof iGetRelevantTemplates>
): ITemplate => iGetRelevantTemplates(...args).first();

export const iGetCommonTemplateCloudInit = (tmp: ITemplate) =>
Copy link
Member

Choose a reason for hiding this comment

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

please make an immutable version of selectVM. Specifying an index is unreliable.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

created

@yaacov
Copy link
Member

yaacov commented Sep 10, 2020

Note:
When using this I get double "cloundinit" disks when I change the "OS" input, and then change it again ...

@glekner
Copy link
Contributor Author

glekner commented Sep 14, 2020

  • Handling of cloudinit disk and volume now works fine when dynamically changing os,flavor,workload when using common templates.
  • I noticed when using a user template, cloud init isn't imported? is this bug known? @jelkosz @suomiy @yaacov

@yaacov
Copy link
Member

yaacov commented Sep 15, 2020

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 15, 2020
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: glekner, yaacov

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

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 15, 2020
@yaacov
Copy link
Member

yaacov commented Sep 15, 2020

I noticed when using a user template, cloud init isn't imported? is this bug known? @jelkosz @suomiy @yaacov

you need to listen to changes in the user template, currently you only listen to common template fields.
but the user template issue can be tracked using a different bug report ( unless you want to fix it using this one ? ).

@openshift-merge-robot openshift-merge-robot merged commit c9afcae into openshift:master Sep 15, 2020
@openshift-ci-robot
Copy link
Contributor

@glekner: All pull requests linked via external trackers have merged:

Bugzilla bug 1876440 has been moved to the MODIFIED state.

In response to this:

Bug 1876440: Cloud init section of common-templates is ignored

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@spadgett spadgett added this to the v4.6 milestone Sep 15, 2020
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. bugzilla/severity-high Referenced Bugzilla bug's severity is high for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. component/kubevirt Related to kubevirt-plugin lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants