Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scan multiple yaml files #3

Open
namnx228 opened this issue Mar 22, 2022 · 3 comments
Open

Scan multiple yaml files #3

namnx228 opened this issue Mar 22, 2022 · 3 comments

Comments

@namnx228
Copy link

Hi,
How can I set the input to multiple files? In details, I want to scan all the yaml files in my repo. Who can I archive that? Thank you!!!

@namnx228
Copy link
Author

cc @06kellyjac

@06kellyjac
Copy link
Member

I was working on multi file scanning in base kubesec but there were race condition issues due to how it was already architected

controlplaneio/kubesec#106

You can try squash all yaml into one file

name: lint
on:
  push:
    branches:
      - master
  pull_request:
jobs:
  lint:
    name: Lint
    runs-on: ubuntu-20.04
    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Collect all yaml
        run: find . -type f -name "*.yaml" -exec sh -c "echo '---' | cat - {}" \; > all.yaml

      - name: Run kubesec scanner
        uses: controlplaneio/kubesec-action@master
        with:
          input: all.yaml

@namnx228
Copy link
Author

Putting files to a single files is a good idea. Thanks!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants