Giter VIP home page Giter VIP logo

Comments (8)

colinjfw avatar colinjfw commented on July 17, 2024

@kierenj ya it's a bit tricky to pass arguments with actions, I wish it would just allow full yaml syntax and pass that along somehow to the action.

The code that does this is here: https://github.com/deliverybot/helm/blob/master/index.js#L81-L97

I believe what's happening is you have a trailing slash in the array which is causing it to be invalid JSON, if it's invalid the action just tries to interpret it as a string. If you remove the trailing slash everything should work :)

from helm.

riker09 avatar riker09 commented on July 17, 2024

This is what I'm doing:

    - uses: deliverybot/helm@v1
      with:
        helm: helm3
        release: foobar
        namespace: default
        chart: path/to/chart
        dry-run: true
        value-files: '["values.yaml", "values.production.yaml"]'

You shouldn't indent the values. If you really want to (eg. for readability) I believe this is valid YAML:

    - uses: deliverybot/helm@v1
      with:
        helm: helm3
        release: foobar
        namespace: default
        chart: path/to/chart
        dry-run: true
        value-files: >-
          [
            "values.yaml", 
            "values.production.yaml",
          ]

Here is helpful information on how to deal with strings that contain multiple new lines: https://yaml-multiline.info/

from helm.

colinjfw avatar colinjfw commented on July 17, 2024

Thanks @riker09 - I think the trailing slash would still cause an error.

from helm.

riker09 avatar riker09 commented on July 17, 2024

What trailing slash are we talking about? I can spot a trailing comma which may cause an error.

from helm.

colinjfw avatar colinjfw commented on July 17, 2024

Ya my bad I actually meant comma

from helm.

riker09 avatar riker09 commented on July 17, 2024

So in conclusion a perfectly valid configuration would look like this:

    - uses: deliverybot/helm@v1
      with:
        helm: helm3
        release: foobar
        namespace: default
        chart: path/to/chart
        dry-run: true
        value-files: >-
          [
            "values.yaml", 
            "values.production.yaml"
          ]

Notice the removed comma on the second to last line.

from helm.

nodox avatar nodox commented on July 17, 2024

There should be a clear example in the README. I've spent hours trying to figure out this problem with this action.

from helm.

colinjfw avatar colinjfw commented on July 17, 2024

@nodox feel free to contribute an example, will be happy to merge it.

from helm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.