---
apiVersion: v1
kind: Template
metadata:
  labels:
    app: generator-backend
    provider: fabric8
    version: 1.0.96
    group: io.fabric8
  name: generator-backend
objects:
- apiVersion: v1
  kind: ServiceAccount
  metadata:
    labels:
      app: generator-backend
      provider: fabric8
      version: 1.0.96
      group: io.fabric8
    name: generator-backend
- apiVersion: v1
  kind: Service
  metadata:
    annotations:
      fabric8.io/git-commit: f1b4c0972d2ee7760c61e1ec00396453286bd752
      fabric8.io/scm-con-url: scm:git:git://github.com/fabric8io/generator-backend.git
      prometheus.io/port: "9779"
      fabric8.io/scm-url: http://github.com/fabric8io/generator-backend
      fabric8.io/issue-system: JIRA
      fabric8.io/iconUrl: img/icons/wildfly.svg
      fabric8.io/issue-tracker-url: https://issues.jboss.org/
      fabric8.io/git-branch: release-v1.0.96
      prometheus.io/scrape: "true"
      fabric8.io/scm-devcon-url: scm:git:git@github.com:fabric8io/generator-backend.git
      fabric8.io/scm-tag: HEAD
    labels:
      expose: "true"
      app: generator-backend
      provider: fabric8
      version: 1.0.96
      group: io.fabric8
    name: generator-backend
  spec:
    ports:
    - name: http
      port: 8080
      protocol: TCP
      targetPort: 8080
    selector:
      app: generator-backend
      provider: fabric8
      group: io.fabric8
- apiVersion: v1
  kind: DeploymentConfig
  metadata:
    annotations:
      fabric8.io/git-commit: f1b4c0972d2ee7760c61e1ec00396453286bd752
      fabric8.io/metrics-path: dashboard/file/kubernetes-pods.json/?var-project=generator-backend&var-version=1.0.96
      fabric8.io/scm-con-url: scm:git:git://github.com/fabric8io/generator-backend.git
      fabric8.io/scm-url: http://github.com/fabric8io/generator-backend
      fabric8.io/issue-system: JIRA
      fabric8.io/iconUrl: img/icons/wildfly.svg
      fabric8.io/issue-tracker-url: https://issues.jboss.org/
      fabric8.io/git-branch: release-v1.0.96
      fabric8.io/scm-devcon-url: scm:git:git@github.com:fabric8io/generator-backend.git
      fabric8.io/scm-tag: HEAD
    labels:
      app: generator-backend
      provider: fabric8
      version: 1.0.96
      group: io.fabric8
    name: generator-backend
  spec:
    replicas: 2
    selector:
      app: generator-backend
      provider: fabric8
      group: io.fabric8
    strategy:
      rollingParams:
        timeoutSeconds: 3600
      type: Rolling
    template:
      metadata:
        annotations:
          fabric8.io/git-commit: f1b4c0972d2ee7760c61e1ec00396453286bd752
          fabric8.io/metrics-path: dashboard/file/kubernetes-pods.json/?var-project=generator-backend&var-version=1.0.96
          fabric8.io/scm-con-url: scm:git:git://github.com/fabric8io/generator-backend.git
          fabric8.io/scm-url: http://github.com/fabric8io/generator-backend
          fabric8.io/issue-system: JIRA
          fabric8.io/iconUrl: img/icons/wildfly.svg
          fabric8.io/issue-tracker-url: https://issues.jboss.org/
          fabric8.io/git-branch: release-v1.0.96
          fabric8.io/scm-devcon-url: scm:git:git@github.com:fabric8io/generator-backend.git
          fabric8.io/scm-tag: HEAD
        labels:
          app: generator-backend
          provider: fabric8
          version: 1.0.96
          group: io.fabric8
      spec:
        containers:
        - env:
          - name: OPENSHIFT_API_URL
            value: ${OPENSHIFT_API_URL}
          - name: KEYCLOAK_SAAS_URL
            value: ${KEYCLOAK_SAAS_URL}
          - name: WIT_URL
            value: ${WIT_URL}
          - name: AUTH_URL
            value: ${AUTH_URL}
          - name: LAUNCHPAD_BACKEND_CATALOG_GIT_REF
            value: v10
          - name: KUBERNETES_NAMESPACE
            valueFrom:
              fieldRef:
                fieldPath: metadata.namespace
          image: fabric8/generator-backend:1.0.96
          imagePullPolicy: IfNotPresent
          livenessProbe:
            failureThreshold: 10
            httpGet:
              path: forge/version
              port: 8080
            initialDelaySeconds: 120
            timeoutSeconds: 3
          name: wildfly-swarm
          ports:
          - containerPort: 8080
            name: http
            protocol: TCP
          - containerPort: 9779
            name: prometheus
            protocol: TCP
          - containerPort: 8778
            name: jolokia
            protocol: TCP
          readinessProbe:
            httpGet:
              path: forge/version
              port: 8080
            initialDelaySeconds: 3
            timeoutSeconds: 3
          securityContext:
            privileged: false
          workingDir: /home
        serviceAccountName: generator-backend
    triggers:
    - type: ConfigChange
parameters:
- name: OPENSHIFT_API_URL
  value: https://api.free-int.openshift.com
- name: KEYCLOAK_SAAS_URL
  value: https://sso.prod-preview.openshift.io
- name: WIT_URL
  value: https://api.prod-preview.openshift.io/
- name: AUTH_URL
  value: https://auth.prod-preview.openshift.io
