How can I create nested lists in YAML? I want to get:
{\"Hello\": [\"as\", [\"http://\", [\"cat\"]]]}
Here\'s my YAML that doesn\'t work (
start nested list from a new line. using this approach it is easy to figure out.
Read this and this articles. They have a lot of examples.
try like this:
YAML
Value:
"Fn::Join":
- ""
-
- "http://"
- "Fn::GetAtt":
- ElasticLoadBalancer
- DNSName
Equivalent JSON
{
"URL": {
"Description": "URL of the website",
"Value": {
"Fn::Join": [
"",
[
"http://",
{
"Fn::GetAtt": [
"ElasticLoadBalancer",
"DNSName"
]
}
]
]
}
}
}