From d0cc6c76fc41239c039f7a317538195513bb5589 Mon Sep 17 00:00:00 2001 From: dengbiao Date: Sat, 17 Aug 2024 16:29:07 +0800 Subject: [PATCH] 1 --- k8s/container.yaml | 8 ++++---- k8s/ingress.yaml | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/k8s/container.yaml b/k8s/container.yaml index 03a3178..2d178d0 100644 --- a/k8s/container.yaml +++ b/k8s/container.yaml @@ -3,7 +3,7 @@ apiVersion: apps/v1 # 元数据 metadata: name: advertisement-agent - namespace: advertisement-agent + namespace: advertisement labels: app: advertisement-agent annotations: @@ -36,9 +36,9 @@ spec: name: advertisement-agent-cfg defaultMode: 420 # pvc - - name: advertisement-agent-pvc # 在该部署中的名称,后面使用改名称挂载 + - name: advertisement-agent # 在该部署中的名称,后面使用改名称挂载 persistentVolumeClaim: - claimName: advertisement-agent-pvc # pvc的名称 + claimName: advertisement-agent # pvc的名称 # Nginx配置 - name: advertisement-agent-nginx configMap: @@ -79,7 +79,7 @@ spec: readOnly: true mountPath: /etc/localtime # 存储卷 用于存放前端代码 - - name: advertisement-agent-pvc # 前面volumes声明的名称 + - name: advertisement-agent # 前面volumes声明的名称 mountPath: /usr/share/nginx/html - name: advertisement-agent-nginx # Nginx 配置 readOnly: true diff --git a/k8s/ingress.yaml b/k8s/ingress.yaml index 78252e4..f3179bb 100644 --- a/k8s/ingress.yaml +++ b/k8s/ingress.yaml @@ -1,7 +1,7 @@ kind: Ingress apiVersion: extensions/v1beta1 metadata: - name: advertisement # ingress名称 + name: advertisement-agent # ingress名称 namespace: advertisement annotations: kubesphere.io/creator: dengbiao @@ -13,5 +13,5 @@ spec: - path: / pathType: ImplementationSpecific backend: - serviceName: advertisement # 流量转发到的服务 + serviceName: advertisement-agent # 流量转发到的服务 servicePort: 80 \ No newline at end of file