stefanprodan / hrval-action

Flux Helm Release validation GitHub action

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cloning Private Chart Repositories

stevenpall opened this issue · comments

Currently if charts are stored in a private repo (even it's the same repository the action is being run against), the clone will fail. Some possible solutions I've thought of:

  • Skip trying to clone the chart repo if it is the same as the target repo; simply use the local path.
  • Use ${{ secrets.GITHUB_TOKEN }}. I'm not exactly sure how this would work with raw Git commands. I believe this also requires the use of https://, so chart git URLs would need to be altered from the ssh://git@github.com format Flux uses.
  • Add the ability to pass in an SSH private key so that the script operates in the same way as Flux.

Thoughts?

Adding an optional isLocal or similar flag could be an option.

@stefanprodan I took a stab at the personal access token approach in #15. I think this is the better solution as it covers situations where charts are stored in the same repo as releases as well as ones where charts are stored in a separate (private) repo.