- Community Home
- >
- Software
- >
- HPE Morpheus Software
- >
- HPE Morpheus Enterprise
- >
- Catalog Field for Multiple Cloud vCenter
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-09-2024 11:47 PM
12-09-2024 11:47 PM
Catalog Field for Multiple Cloud vCenter
Hi,
I have multiple vcenter integrated to morpheus, and i made a catalog form so user able to choose which vcenter that they want to placed the instance. Also i have different policy name for each vcenter, let say if VM deployed to VCSA1 then hostname/vmname should be named with prefix VC1xxx, and if VM goes to VCSA2, then hostname/vmname should be named with prefix VC2xxx.
VCSA1 cloud ID is 12, and VCSA2 cloud ID is 15, so i made the catalog condition for hostname and vmname as this below code.
“name”: “<%=if (customOptions.cloudname == 12 ){‘VC1’} else {‘VC2’}%><%=customOptions.hostname.toUpperCase()%>”,
“hostName”: “<%=if (customOptions.cloudname == 12 ){‘VC1’} else {‘VC2’}%><%=customOptions.hostname.toUpperCase()%>”,
In form catalog, field for cloud option have 2 lists in dropdown/select list, VCSA1 and VCSA2. When i go to this catalog is VCSA1, and submitted it, it was works as name format expected that use VC1xxx, also if i choose VCSA2, it was works as expected too using VC2xxx,
BUT when i choose VCSA2, then going back to choose VCSA1, the name still using VC2 which is used by VCSA2, it supposed to using VC1xxx.
Please help if there something i missed to make it happen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2024 02:10 AM
12-11-2024 02:10 AM
Re: Catalog Field for Multiple Cloud vCenter
I just using “cloud” type for this field. and when i use check the element as your advice before, i tried to change the cloud list in form catalog to VCSA2 and reverse to VCSA1, but in network tabs, only price was generated new one, for cloud, there’s nothing changed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2024 05:22 AM
12-10-2024 05:22 AM
Re: Catalog Field for Multiple Cloud vCenter
If you inspect the page in chrome, when on the network tab you should see a ‘price’ object when making changes assuming pricing is on. Select that and then choose payload. Inspect the payload to see if the value is actu ally changing.
Also, do you have a ‘select’ option in your list? or only the 2 values? You may need to evaluate your variables like:
customOptions?.cloudname the ? tells groovy to only evaluate if the value exists.