defenseunicorns/lula

Add command for getting resources directly from a validation statement

Closed this issue · 0 comments

Add a command to extract resources from a validation manifest directly.

Input would be a yaml manifest for validation, such as:

target:
  provider: opa
  domain: kubernetes
  payload:
    resources:
      - name: deployment
        resource-rule:
          name: monitoring-grafana
          group: apps
          version: v1
          resource: deployments
          namespaces: [monitoring]
    rego: |
      package validate
      
      default validate = false

Output would be a json file or json to stdout that represents the resources, which would be inputs to the rego