Bug 2096780 - [RFE] Add ssh-key and sysprep to template scripts tab
Summary: [RFE] Add ssh-key and sysprep to template scripts tab
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: User Experience
Version: 4.11.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.12.0
Assignee: Ugo Palatucci
QA Contact: Guohua Ouyang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-06-14 09:04 UTC by Guohua Ouyang
Modified: 2023-01-24 13:36 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-01-24 13:36:39 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt-ui kubevirt-plugin pull 676 0 None Merged Bug 2096780: Template Auth SSH Service 2022-08-08 13:07:46 UTC
Github kubevirt-ui kubevirt-plugin pull 682 0 None Merged Bug 2096780: Wizard Sysprep modal with existing sysprep selection 2022-08-08 13:07:51 UTC
Github kubevirt-ui kubevirt-plugin pull 712 0 None Merged Bug 2096780: Template sysprep selection 2022-08-08 13:07:52 UTC
Github kubevirt-ui kubevirt-plugin pull 815 0 None Merged Bug 2096780: Add Sysprep in template Objects array 2022-08-08 13:07:52 UTC
Github kubevirt-ui kubevirt-plugin pull 824 0 None Merged Bug 2096780: template create secret object 2022-08-24 18:16:15 UTC
Github kubevirt-ui kubevirt-plugin pull 831 0 None Merged Bug 2096780: Wizard with ssh key in additionalResources 2022-08-24 18:16:15 UTC
Github kubevirt-ui kubevirt-plugin pull 833 0 None Merged Bug 2096780: Wizard with sysprep in additionalResources 2022-08-24 18:16:16 UTC
Red Hat Issue Tracker CNV-19111 0 None None None 2022-12-15 08:44:14 UTC
Red Hat Product Errata RHSA-2023:0408 0 None None None 2023-01-24 13:36:49 UTC

Internal Links: 2150364

Description Guohua Ouyang 2022-06-14 09:04:19 UTC
Description of problem:
Currently, only cloud-init data are added to the template scripts tab, user will wonder why there are no ssh-key and sysprep data showing there.
Such as for a windows template, user may want the sysprep configured in the template, so they won't provider the sysprep file every time while they creating their windows VM.

Version-Release number of selected component (if applicable):
CNV 4.11

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Guohua Ouyang 2022-07-27 04:32:59 UTC
Now it has the ssh-key and sysprep in the template's scripts tab, but it's not like the VM's scripts tab.
It's trying to add an existing secret instead of adding new ssh-key or sysprep file.

Comment 2 Ugo Palatucci 2022-08-02 09:24:36 UTC
@yzamir 

Yes, this is the desired behavior. 
In VM and wizard, we can choose from creating new secret/sysprep just for that single VM or selecting an existing one in the same namespace.
We decided in the template to don't let the user create new secret/sysprep but just choose existing ones.
It's not really feasible to enable the user to create n equal secrets/syspreps resources that can be simply shared across namespaces.

Comment 3 Yaacov Zamir 2022-08-02 10:02:29 UTC
(In reply to Ugo Palatucci from comment #2)
> @yzamir 
> 
> Yes, this is the desired behavior. 
> In VM and wizard, we can choose from creating new secret/sysprep just for
> that single VM or selecting an existing one in the same namespace.
> We decided in the template to don't let the user create new secret/sysprep
> but just choose existing ones.
> It's not really feasible to enable the user to create n equal
> secrets/syspreps resources that can be simply shared across namespaces.

It's by design, only when you create a VM we allow to create a new secret just for the VM
we do not support this feature in the templates overview.

for the future:
when working with templates, we currently do not allow to create a new services/secrets/routes... using the template.
when we will allow to add additional objects to a template, it may be nice to allow to add new secrets for ssh and sysprep

Comment 4 Ugo Palatucci 2022-08-05 09:06:17 UTC
Okay working on that. 

Recently we fixed the bug regarding template with multiple objects ( https://bugzilla.redhat.com/show_bug.cgi?id=2060499 )
so now we can continue with this.

Comment 5 Leon Kladnitsky 2022-08-24 18:18:12 UTC
Verified on v4.12.0-109

Comment 9 errata-xmlrpc 2023-01-24 13:36:39 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Important: OpenShift Virtualization 4.12.0 Images security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2023:0408


Note You need to log in before you can comment on or make changes to this bug.