Skip to content
Snippets Groups Projects
Commit a5b18955 authored by Ling Zhu's avatar Ling Zhu
Browse files

Add deploymnet file

parent d0a3bff5
No related branches found
No related tags found
No related merge requests found
---
kind: Service
apiVersion: v1
metadata:
name: apex-svc
spec:
selector:
app: apex
ports:
- name: ui
protocol: "TCP"
# Port accessible inside cluster
port: 8080
# Port to forward to inside the pod
targetPort: http
# Port accessible outside cluster
nodePort: 30080
- name: tcp-1
protocol: "TCP"
# Port accessible inside cluster
port: 12345
# Port to forward to inside the pod
targetPort: tcp1
# Port accessible outside cluster
nodePort: 32345
- name: tcp-2
protocol: "TCP"
# Port accessible inside cluster
port: 18989
# Port to forward to inside the pod
targetPort: tcp2
# Port accessible outside cluster
nodePort: 28989
- name: tcp-3
protocol: "TCP"
# Port accessible inside cluster
port: 23324
# Port to forward to inside the pod
targetPort: tcp3
# Port accessible outside cluster
nodePort: 23324
type: NodePort #LoadBalancer
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: apex
labels:
app: apex
spec:
selector:
matchLabels:
app: apex
replicas: 1
template:
metadata:
labels:
app: apex
spec:
containers:
- name: apex
image: gitlab-registry.eps.surrey.ac.uk/noc/apex:example
#command: ["sh", "-c", "while true; do sleep 3600; done"]
command: ["sh", "-c", "/apex/start.sh"]
ports:
- name: http
containerPort: 8080
- name: tcp1
containerPort: 12345
- name: tcp2
containerPort: 18989
- name: tcp3
containerPort: 23324
imagePullPolicy: IfNotPresent
restartPolicy: Always
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment