apiVersion: v1 kind: Service metadata: name: whoami namespace: whoami spec: type: NodePort ports: - port: 80 targetPort: 80 nodePort: 31338 selector: app: whoami