VOL-569: Create kubernetes deployment configuration for each voltha service
This update:
- renames all voltha images referenced in kubernetes deployment files
to the 'voltha-<component>' format
- adds the kubernetes deployment files for grafana, dashd, and shovel
- adds deployment files for an Ingress resource and an nginx-based ingress
controller to allow access to the Consul and Grafana UIs from outside
the cluster
Manifest file ingress/05-namespace.yml sets up a namespace 'ingress-nginx'
for all ingress-related resources. This file will be deleted once we move
all voltha components, including ingress, to a 'voltha' namespace.
Deployment instructions for the ingress resources are provided in README.md.
Change-Id: I0459e838318c43e21f40e83b314f77fc9e0456f8
diff --git a/k8s/grafana.yml b/k8s/grafana.yml
new file mode 100644
index 0000000..c6fa94d
--- /dev/null
+++ b/k8s/grafana.yml
@@ -0,0 +1,56 @@
+#
+# The grafana service
+#
+apiVersion: v1
+kind: Service
+metadata:
+ name: grafana
+spec:
+ clusterIP: None
+ selector:
+ app: grafana
+ ports:
+ - name: ui-port
+ protocol: TCP
+ port: 8883
+ targetPort: 80
+ - name: port-2003
+ protocol: TCP
+ port: 2003
+ targetPort: 2003
+ - name: port-2004
+ protocol: TCP
+ port: 2004
+ targetPort: 2004
+ - name: port-8126
+ protocol: TCP
+ port: 8126
+ targetPort: 8126
+ - name: port-8125
+ protocol: TCP
+ port: 8125
+ targetPort: 8125
+---
+apiVersion: apps/v1beta1
+kind: Deployment
+metadata:
+ name: grafana
+spec:
+ replicas: 1
+ template:
+ metadata:
+ labels:
+ app: grafana
+ spec:
+ containers:
+ - name: grafana
+ image: kamon/grafana_graphite:3.0
+ ports:
+ - containerPort: 80
+ - containerPort: 2003
+ - containerPort: 2004
+ - containerPort: 8126
+ - containerPort: 8125
+ env:
+ - name: GR_SERVER_ROOT_URL
+ value: "http://localhost:80/grafana/"