Pārlūkot izejas kodu

deploy qa/offline-process-charge:r180485 测试阿里云k8s集群部署

datard 2 gadi atpakaļ
vecāks
revīzija
4e288fd184
4 mainītis faili ar 13 papildinājumiem un 15 dzēšanām
  1. 4 6
      .drone.yml
  2. 1 1
      Dockerfile
  3. 8 6
      deploy-tmp.yaml
  4. 0 2
      drone.template.yml

+ 4 - 6
.drone.yml

@@ -21,7 +21,7 @@ steps:
   environment:
     JNLP_ENV: qa
     JNLP_REPLICAS: 1
-    JNLP_TAG: r180484
+    JNLP_TAG: r180485
     JNLP_VERSION: v1  # default v1, v2 for canary
     DEPLOY_ENV: k8s-1 # 可以选择把应用部署到集群:k8s-1 or k8s-2
     JNLP_REPO: hub.evbj.easou.com
@@ -45,8 +45,6 @@ steps:
     - python3 /root/tools.py -b
     # 部署服务到kubernetes上
     - python3 /root/tools.py -a
-    # 检查服务部署状态
-    - python3 /root/tools.py -c
     # 添加dns解析记录,生成访问域名
     - python3 /root/tools.py -d
 
@@ -56,8 +54,8 @@ steps:
     corpid: ww419ee4063735e1c0
     corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
     agent_id: 1000004
-    title: "Pipeline qa/offline-process-charge:r180484 Success"
-    description: "${DRONE_BUILD_LINK} qa/offline-process-charge:r180484 部署完成 测试阿里云k8s集群部署"
+    title: "Pipeline qa/offline-process-charge:r180485 Success"
+    description: "${DRONE_BUILD_LINK} qa/offline-process-charge:r180485 部署完成 测试阿里云k8s集群部署"
     msg_url: ${DRONE_BUILD_LINK}
     btn_txt: "否"
   when:
@@ -70,7 +68,7 @@ steps:
     corpid: ww419ee4063735e1c0
     corp_secret: zpiRBLETH9eLwIMQ4eJ_r_dcm3BPSGeLHvTcft8Ot-M
     agent_id: 1000004
-    title: "Pipeline qa/offline-process-charge:r180484 Failure"
+    title: "Pipeline qa/offline-process-charge:r180485 Failure"
     description: "${DRONE_BUILD_LINK} 部署失败,请检查配置!测试阿里云k8s集群部署"
     msg_url: ${DRONE_BUILD_LINK}
     btn_txt: "否"

+ 1 - 1
Dockerfile

@@ -1 +1 @@
-FROM hub.evbj.easou.com/qa/offline-process-charge:r180484
+FROM hub.evbj.easou.com/qa/offline-process-charge:r180485

+ 8 - 6
deploy-tmp.yaml

@@ -49,7 +49,7 @@ spec:
               topologyKey: kubernetes.io/hostname
       containers:
         - name: offline-process-charge
-          image: hub.evbj.easou.com/qa/offline-process-charge:r180484
+          image: hub.evbj.easou.com/qa/offline-process-charge:r180485
           imagePullPolicy: IfNotPresent
           env:
             - name: MY_NODE_NAME
@@ -144,22 +144,24 @@ spec:
   selector:
     app: offline-process-charge
 ---
-apiVersion: extensions/v1beta1
+apiVersion: networking.k8s.io/v1
 kind: Ingress
 metadata:
   name: offline-process-charge-ingress
   namespace: qa
-  annotations:
-    kubernetes.io/ingress.class: nginx
 spec:
   rules:
     - host: qa-offline-process-charge.ieasou.cn
       http:
         paths:
           - path: /
+            pathType: Prefix
             backend:
-              serviceName: offline-process-charge-svc
-              servicePort: 80
+              service:
+                name: offline-process-charge-svc
+                port:
+                  number: 8080
+  ingressClassName: nginx
 ---
 apiVersion: v1
 kind: ConfigMap

+ 0 - 2
drone.template.yml

@@ -45,8 +45,6 @@ steps:
     - python3 /root/tools.py -b
     # 部署服务到kubernetes上
     - python3 /root/tools.py -a
-    # 检查服务部署状态
-    - python3 /root/tools.py -c
     # 添加dns解析记录,生成访问域名
     - python3 /root/tools.py -d