port-allocator: allocates ports on preconfigured ingress-nginx
Replacement of /core/installer/tcp-udp-transport
Change-Id: I3d116b0f4508b462398f69e980ad55771dc88b7c
diff --git a/charts/port-allocator/templates/install.yaml b/charts/port-allocator/templates/install.yaml
new file mode 100644
index 0000000..ec7a144
--- /dev/null
+++ b/charts/port-allocator/templates/install.yaml
@@ -0,0 +1,60 @@
+apiVersion: v1
+kind: Secret
+metadata:
+ name: ssh-key
+type: Opaque
+data:
+ private: {{ .Values.sshPrivateKey }}
+---
+apiVersion: v1
+kind: Service
+metadata:
+ name: port-allocator
+ namespace: {{ .Release.Namespace }}
+spec:
+ type: ClusterIP
+ selector:
+ app: port-allocator
+ ports:
+ - name: http
+ port: 80
+ targetPort: http
+ protocol: TCP
+---
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+ name: port-allocator
+ namespace: {{ .Release.Namespace }}
+spec:
+ selector:
+ matchLabels:
+ app: port-allocator
+ replicas: 1
+ template:
+ metadata:
+ labels:
+ app: port-allocator
+ spec:
+ volumes:
+ - name: ssh-key
+ secret:
+ secretName: ssh-key
+ containers:
+ - name: port-allocator
+ image: {{ .Values.image.repository }}:{{ .Values.image.tag }}
+ imagePullPolicy: {{ .Values.image.pullPolicy }}
+ ports:
+ - name: http
+ containerPort: 8080
+ protocol: TCP
+ command:
+ - server
+ - --port=8080
+ - --repo-addr={{ .Values.repoAddr }}
+ - --ssh-key=/pcloud/ssh-key/private
+ - --ingress-nginx-path={{ .Values.ingressNginxPath }}
+ volumeMounts:
+ - name: ssh-key
+ readOnly: true
+ mountPath: /pcloud/ssh-key