David Bainbridge | 2f9b76f | 2019-05-15 13:48:11 -0700 | [diff] [blame] | 1 | # Copyright 2019-present Open Networking Foundation |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | |
| 15 | --- |
| 16 | apiVersion: apps/v1beta1 |
| 17 | kind: Deployment |
| 18 | metadata: |
| 19 | name: ofagent |
| 20 | serviceAccountName: {{ .Values.serviceaccount }} |
| 21 | spec: |
| 22 | replicas: {{ .Values.replicas.ofagent }} |
| 23 | template: |
| 24 | metadata: |
| 25 | labels: |
| 26 | app: ofagent |
David Bainbridge | 1f88804 | 2019-06-24 18:02:01 +0000 | [diff] [blame^] | 27 | app.kubernetes.io/name: "open-flow-agent" |
| 28 | app.kubernetes.io/version: {{ quote .Chart.AppVersion }} |
| 29 | app.kubernetes.io/component: "integration" |
| 30 | app.kubernetes.io/part-of: "voltha" |
| 31 | app.kubernetes.io/managed-by: {{ quote .Release.Service }} |
| 32 | helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" |
David Bainbridge | 2f9b76f | 2019-05-15 13:48:11 -0700 | [diff] [blame] | 33 | annotations: |
| 34 | cni: "calico" |
| 35 | spec: |
| 36 | terminationGracePeriodSeconds: 10 |
| 37 | serviceAccountName: {{ .Values.serviceaccount }} |
| 38 | containers: |
| 39 | - name: ofagent |
David Bainbridge | cd30e54 | 2019-05-31 20:52:56 +0000 | [diff] [blame] | 40 | image: {{ tpl .Values.images.ofagent.registry . }}{{ tpl .Values.images.ofagent.repository . }}:{{ tpl .Values.images.ofagent.tag . }} |
| 41 | imagePullPolicy: {{ tpl .Values.images.ofagent.pullPolicy . }} |
David Bainbridge | 2f9b76f | 2019-05-15 13:48:11 -0700 | [diff] [blame] | 42 | env: |
| 43 | - name: CONTROLLER_SERVICE |
| 44 | value: "{{ .Values.services.controller.service }}:{{ .Values.services.controller.port }}" |
| 45 | args: |
| 46 | - "/ofagent/ofagent/main.py" |
| 47 | - "-v" |
| 48 | - "--controller=$(CONTROLLER_SERVICE)" |
| 49 | - "--grpc-endpoint=voltha-api.{{ .Release.Namespace }}.svc.cluster.local:55555" |