Skip to content

Implement custom validation checks #16

@jkupferer

Description

@jkupferer

Custom validation checks should process using jinja2 to validate check conditions:

spec:
  validation:
    customValidation:
    - name: destroy schedule must be no more than 14 days from creation
      check: spec.actionSchedule.destroy < timestamp(resource_claim.metadata.creationTimestamp).add('14d')
    - name: stop schedule must be no more than 8 hours from now
      check: spec.actionSchedule.stop < timestamp.utcnow.add('8h')

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions