apiVersion: apps/v1
kind: Deployment
metadata:
  name: gravitee-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: gravitee-operator
  template:
    metadata:
      labels:
        name: gravitee-operator
    spec:
      serviceAccountName: gravitee-operator
      containers:
        - name: gravitee-operator
          image: devcsrj/gravitee-operator:latest
          command:
          - gravitee-operator
          imagePullPolicy: IfNotPresent
          env:
            - name: WATCH_NAMESPACE
              valueFrom:
                fieldRef:
                  fieldPath: metadata.namespace
            - name: POD_NAME
              valueFrom:
                fieldRef:
                  fieldPath: metadata.name
            - name: OPERATOR_NAME
              value: "gravitee-operator"
            - name: GRAVITEE_APIM_URL
              value: "http://graviteeio-apim-api:83"
            - name: GRAVITEE_APIM_USERNAME
              value: "admin"
            - name: GRAVITEE_APIM_PASSWORD
              value: "admin"
            - name: GRAVITEE_APIM_TIMEOUTMS
              value: "5000"
