VMware Cloud Community
mike_probst
Contributor
Contributor
Jump to solution

vra8.6 extra space inserted into vm name

I am having problems with a space getting inserted into my VM name if I use a conditional in my yml.

I have the Custom Naming for the project set as:   ${resource.name}0${####}

 

in my yml if I use this line, I get a name like  "lxdev 01234" with the space before the #'s

resources:
  Cloud_vSphere_Machine_1:
    type: Cloud.vSphere.Machine
    properties:
      name: '${input.LinuxServer.Environment == "Development" ? "lxdev" : "lxprod" } '

 

and if I use it more hardcoded like this example, I get a name without the space like I expect to get with both  "lxdev01234"

resources:
  Cloud_vSphere_Machine_1:
    type: Cloud.vSphere.Machine
    properties:
       name: lxdev

 

What would be causing the addition of the space? 

 

 

0 Kudos
1 Solution

Accepted Solutions
xian_
Expert
Expert
Jump to solution

Remove this extra space:

name: '${input.LinuxServer.Environment == "Development" ? "lxdev" : "lxprod" }🟥'

View solution in original post

1 Reply
xian_
Expert
Expert
Jump to solution

Remove this extra space:

name: '${input.LinuxServer.Environment == "Development" ? "lxdev" : "lxprod" }🟥'