Breaking News: Grepper is joining You.com. Read the official announcement!
Check it out

Defining Multiple Objects in the Same YAML file

Sumit Rawal answered on June 23, 2023 Popularity 1/10 Helpfulness 1/10

Contents


More Related Answers

  • yaml syntax multiple values
  • Merging Everything into the Same YAML Definition

  • Defining Multiple Objects in the Same YAML file

    0

    All the YAML files defined in the previous lesson for pods, services, and API work together. But having four YAML definitions is confusing. It would get even more confusing later on since we are going to add more objects to the stack. Things would be much simpler and easier if we would move all the objects we created thus far into a single YAML definition. Fortunately, that is very easy to accomplish.

    Let’s take a look at yet another YAML file go-demo-2.yml in the code playground at the end of the lesson. It is the same as the contents of the previous four YAML files combined. The only difference is that each object definition is separated by three dashes (---).

    We will create the objects defined in the go-demo-2.yml in this lesson: 

    Popularity 1/10 Helpfulness 1/10 Language typescript
    Source: Grepper
    Link to this answer
    Share Copy Link
    Contributed on Jun 23 2023
    Sumit Rawal
    0 Answers  Avg Quality 2/10


    X

    Continue with Google

    By continuing, I agree that I have read and agree to Greppers's Terms of Service and Privacy Policy.
    X
    Grepper Account Login Required

    Oops, You will need to install Grepper and log-in to perform this action.