Skip to content

Depth for Object to use in ConvertTo-Yaml changed from 0.4.2 to 0.4.12 #182

@falkheiland

Description

@falkheiland

while back in 0.4.2 i could create a ansible inventory with a depth of 7, this is not possible in 0.4.12 anymore. here the depth seems to be restricted to 6. this leads to the following result:

- all:
    children:
      appliance:
        hosts:
          CAG:
            ansible_host:
            - Length: 14
            - Length: 14
            - Length: 14

while with 0.4.2:

- all:
    children:
      appliance:
        hosts:
          CAG:
            ansible_host:
            - 192.168.0.1
            - 192.168.0.2
            - 192.168.0.3
$YamlColl.all.children.appliance.hosts.CAG | ConvertTo-Yaml

ansible_host:
- 192.168.0.1
- 192.168.0.2
- 192.168.0.3


$YamlColl.all | ConvertTo-Yaml

children:
  appliance:
    hosts:
      CAG:
        ansible_host:
        - 192.168.0.1
        - 192.168.0.2
        - 192.168.0.3


$YamlColl | ConvertTo-Yaml

all:
  children:
    appliance:
      hosts:
        CAG:
          ansible_host:
          - Length: 14
          - Length: 14
          - Length: 14

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions