# Copyright 2020 Nokia
# Licensed under the Apache License 2.0.
# SPDX-License-Identifier: Apache-2.0



apiVersion: apps/v1
kind: Deployment
metadata:
  name: nuage-network-operator
  namespace: nuage-network-operator
spec:
  replicas: 1
  selector:
    matchLabels:
      name: nuage-network-operator
  template:
    metadata:
      labels:
        name: nuage-network-operator
    spec:
      tolerations:
      - key:  "node.kubernetes.io/not-ready"
        operator: "Exists"
        effect: "NoSchedule"
      serviceAccountName: nuage-network-operator
      hostNetwork: true
      containers:
        - name: nuage-network-operator
          # Replace this with the built image name
          image: nuage/nuage-network-operator:latest
          command:
          - /nuage-network-operator
          imagePullPolicy: Always
          env:
            - name: WATCH_NAMESPACE
              value: ""
            - name: POD_NAME
              valueFrom:
                fieldRef:
                  fieldPath: metadata.name
            - name: OPERATOR_NAME
              value: "nuage-network-operator"
