From 2444c35eb9bec3972e88d2b98df9fd152593ac49 Mon Sep 17 00:00:00 2001 From: Arnaud Meukam Date: Sat, 11 Sep 2021 02:44:24 +0200 Subject: [PATCH] apps: Switch jobs to ClusterIP and NEG Ref: https://github.com/kubernetes/k8s.io/issues/2488. Convert kubernetes services for world-accessible from NodePort to ClusterIP. Signed-off-by: Arnaud Meukam --- apps/sippy/service.yaml | 4 +++- apps/slack-infra/resources/slack-event-log/service.yaml | 4 +++- apps/slack-infra/resources/slack-moderator-words/service.yaml | 4 +++- apps/slack-infra/resources/slack-moderator/service.yaml | 4 +++- apps/slack-infra/resources/slack-post-message/service.yaml | 4 +++- apps/slack-infra/resources/slack-welcomer/service.yaml | 4 +++- apps/slack-infra/resources/slackin/service.yaml | 4 +++- apps/triageparty-release/service.yaml | 4 +++- 8 files changed, 24 insertions(+), 8 deletions(-) diff --git a/apps/sippy/service.yaml b/apps/sippy/service.yaml index f5d3e24b074..0632fed36ba 100644 --- a/apps/sippy/service.yaml +++ b/apps/sippy/service.yaml @@ -5,6 +5,8 @@ metadata: namespace: sippy labels: app: sippy + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: ports: - port: 9080 @@ -13,4 +15,4 @@ spec: selector: app: sippy sessionAffinity: None - type: NodePort + type: ClusterIP diff --git a/apps/slack-infra/resources/slack-event-log/service.yaml b/apps/slack-infra/resources/slack-event-log/service.yaml index f0fe98faa54..cb070bb0d21 100644 --- a/apps/slack-infra/resources/slack-event-log/service.yaml +++ b/apps/slack-infra/resources/slack-event-log/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slack-event-log + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slack-event-log - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/slack-infra/resources/slack-moderator-words/service.yaml b/apps/slack-infra/resources/slack-moderator-words/service.yaml index 05b26e1cc16..a0b829bf3a1 100644 --- a/apps/slack-infra/resources/slack-moderator-words/service.yaml +++ b/apps/slack-infra/resources/slack-moderator-words/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slack-moderator-words + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slack-moderator-words - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/slack-infra/resources/slack-moderator/service.yaml b/apps/slack-infra/resources/slack-moderator/service.yaml index 2b41b47158f..b4c27e320e2 100644 --- a/apps/slack-infra/resources/slack-moderator/service.yaml +++ b/apps/slack-infra/resources/slack-moderator/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slack-moderator + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slack-moderator - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/slack-infra/resources/slack-post-message/service.yaml b/apps/slack-infra/resources/slack-post-message/service.yaml index f3f31bcd3cb..9bd1d089023 100644 --- a/apps/slack-infra/resources/slack-post-message/service.yaml +++ b/apps/slack-infra/resources/slack-post-message/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slack-post-message + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slack-post-message - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/slack-infra/resources/slack-welcomer/service.yaml b/apps/slack-infra/resources/slack-welcomer/service.yaml index 554951fadd4..00c484e715e 100644 --- a/apps/slack-infra/resources/slack-welcomer/service.yaml +++ b/apps/slack-infra/resources/slack-welcomer/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slack-welcomer + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slack-welcomer - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/slack-infra/resources/slackin/service.yaml b/apps/slack-infra/resources/slackin/service.yaml index 72a65b54d7b..2d84f8facff 100644 --- a/apps/slack-infra/resources/slackin/service.yaml +++ b/apps/slack-infra/resources/slackin/service.yaml @@ -2,10 +2,12 @@ kind: Service apiVersion: v1 metadata: name: slackin2 + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: selector: app: slackin2 - type: NodePort + type: ClusterIP ports: - protocol: TCP port: 80 diff --git a/apps/triageparty-release/service.yaml b/apps/triageparty-release/service.yaml index 74b2605c8cd..28e81984708 100644 --- a/apps/triageparty-release/service.yaml +++ b/apps/triageparty-release/service.yaml @@ -5,8 +5,10 @@ metadata: namespace: triageparty-release labels: app: triage-party + annotations: + cloud.google.com/neg: '{"ingress": true}' spec: - type: NodePort + type: ClusterIP ports: - port: 8080 protocol: TCP