k8s-mgmt-pod/k8s/service.yaml
Michael Trip 5584dc1f29
All checks were successful
Build k8s-mgmt-pod image / Build & Push (push) Successful in 1m35s
Update SSH port from 22 to 2222 in Dockerfile, entrypoint, and Kubernetes configurations
2026-06-23 15:48:15 +02:00

34 lines
707 B
YAML

apiVersion: v1
kind: Service
metadata:
name: k8s-mgmt-pod
spec:
type: ClusterIP
selector:
app.kubernetes.io/name: k8s-mgmt-pod
ports:
- name: ssh
port: 2222
targetPort: ssh
protocol: TCP
- name: webssh
port: 3000
targetPort: webssh
protocol: TCP
# Expose externally only if you explicitly want SSH and web SSH reachable from outside the cluster.
# apiVersion: v1
# kind: Service
# metadata:
# name: k8s-mgmt-pod-external
# spec:
# type: LoadBalancer
# selector:
# app.kubernetes.io/name: k8s-mgmt-pod
# ports:
# - name: ssh
# port: 2222
# targetPort: ssh
# - name: webssh
# port: 3000
# targetPort: webssh