stackrox/kube-linter

[FEATURE_REQUEST] env-var template for validating environment variables in ConfigMap

jeraldsm opened this issue · 1 comments

Description of the problem/feature request
As a Developer, I would like to validate if the environment variables configured in the ConfigMap matches a specific pattern.
Example:

---
apiVersion: v1
kind: ConfigMap
metadata:
  name: app-config
data:
  APP_TAGS: example-value

Description of the existing behavior vs. expected behavior

The validation of environment variables is currently possible only for deployment objects and it wont validate the variables defined in ConfigMap. But we define the environment specific variables in ConfigMap.
So it would be great, if we have something similar to this:

  - name: app-configmap-env-var-check
    template: env-var
    params:
      name: APP_TAGS
      value: "!(example-value)"
    scope:
      objectKinds:
        - ConfigMap

Hi @janisz

Do you have an ETA for implementing this feature ?
Just wanted to check if this feature can be implemented at the earliest, as I was working on project which needs this feature.

Many Thanks.
Jerald