apiVersion: build.openshift.io/v1
kind: BuildConfig
metadata:
  name: monitor-gating-build
  labels:
    environment: "monitor-gating"
spec:
  source:
    git:
{% if env == 'staging' %}
      uri: https://pagure.io/fedora-ci/monitor-gating.git
      ref: "staging"
{% else %}
      uri: https://pagure.io/fedora-ci/monitor-gating.git
      ref: "production"
{% endif %}
  strategy:
    type: Docker
  triggers:
  - type: ConfigChange
  - type: ImageChange
  output:
    to:
      kind: ImageStreamTag
      name: monitor-gating:latest
