launchdarkly_feature_flag_validator – Validate Flags against Conftest OPA Policies written in Rego

New in version 0.3.0.

Synopsis

  • Validate Feature Flags in a Project. Conftest 0.18.0 is required as a binary in your PATH.

Parameters

Parameter Choices/Defaults Comments
api_key
string / required
LaunchDarkly API Key. May be set as LAUNCHDARKLY_ACCESS_TOKEN environment variable.
conftest
string
Run a conftest policy when creating resource.
dir
string
Directory to look for policy
enabled
boolean
    Choices:
  • no
  • yes
Run Policy
namespace
string
Default:
"launchdarkly"
Conftest namespace to apply
env
string
Filter for a specific environment.
project_key
- / required
Default:
"default"
Project key will group flags together

Examples

# Get list of flags filtered to production environment.
- launchdarkly_feature_flag_info:
    api_key: api-12345
    project_key: dano-test-project

Return Values

Common return values are documented here, the following are the fields unique to this :

Key Returned Description
validated
boolean
always
If the policies were all successfully validated.

validation
-
failure
List of Dictionaries, container flag key and list of failures as strings.



Status

  • This is not guaranteed to have a backwards compatible interface. [preview]

  • This is maintained by the Ansible Community. [community]

Hint

If you notice any issues in this documentation, you can edit this document to improve it.

Hint

Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.