zyx 2 gadi atpakaļ
vecāks
revīzija
a1f8dec4a0
4 mainītis faili ar 1 papildinājumiem un 114 dzēšanām
  1. 0 11
      deploy/binlog.sh
  2. 1 1
      deploy/build.sh
  3. 0 51
      deploy/huaqiyun-binlog.yml
  4. 0 51
      deploy/taide-binlog.yml

+ 0 - 11
deploy/binlog.sh

@@ -1,11 +0,0 @@
-cd `dirname $0`
-cd ../
-
-version=$(date +%s)
-docker build -t registry.cn-chengdu.aliyuncs.com/cxzx-spider/binlog:$version .
-docker push registry.cn-chengdu.aliyuncs.com/cxzx-spider/binlog:$version
-sed -i "s!{ { image } }!registry\.cn-chengdu\.aliyuncs\.com/cxzx-spider/binlog:$version!g" deploy/taide-binlog.yml
-sed -i "s!{ { image } }!registry\.cn-chengdu\.aliyuncs\.com/cxzx-spider/binlog:$version!g" deploy/huaqiyun-binlog.yml
-
-kubectl apply -f deploy/taide-binlog.yml
-kubectl apply -f deploy/huaqiyun-binlog.yml

+ 1 - 1
deploy/build.sh

@@ -2,6 +2,6 @@ cd `dirname $0`
 cd ../
 git reset HEAD --hard
 git pull
-gradle build
+gradle build -Dorg.gradle.java.home=/opt/jdk-17.0.4.1
 
 

+ 0 - 51
deploy/huaqiyun-binlog.yml

@@ -1,51 +0,0 @@
-apiVersion: apps/v1
-kind: Deployment
-metadata:
-  name: huaqiyun-binlog
-spec:
-  replicas: 1
-  selector:
-    matchLabels:
-      k8s-app: huaqiyun-binlog
-  strategy:
-    type: Recreate
-  template:
-    metadata:
-      labels:
-        k8s-app: huaqiyun-binlog
-    spec:
-      hostAliases:
-        - ip: "172.16.101.16"
-          hostnames:
-            - "baidu06"
-        - ip: "172.16.101.17"
-          hostnames:
-            - "baidu07"
-        - ip: "172.16.101.18"
-          hostnames:
-            - "baidu08"
-        - ip: "172.16.101.19"
-          hostnames:
-            - "baidu09"
-      imagePullSecrets:
-        - name: registry-key
-      containers:
-        - command: [ "java","-cp","/app.jar","com.cxzx.canal.CanalClientMain","huaqiyun","huaqiyun-binlog" ]
-          env:
-            - name: PATH
-              value: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
-            - name: TZ
-              value: Asia/Shanghai
-          image: { { image } }
-          imagePullPolicy: IfNotPresent
-          name: huaqiyun-binlog
-          resources:
-            limits:
-              cpu: 100m
-              memory: 515Mi
-            requests:
-              cpu: 100m
-              memory: 50Mi
-      dnsPolicy: ClusterFirst
-      terminationGracePeriodSeconds: 10
-

+ 0 - 51
deploy/taide-binlog.yml

@@ -1,51 +0,0 @@
-apiVersion: apps/v1
-kind: Deployment
-metadata:
-  name: taide-binlog
-spec:
-  replicas: 1
-  selector:
-    matchLabels:
-      k8s-app: taide-binlog
-  strategy:
-    type: Recreate
-  template:
-    metadata:
-      labels:
-        k8s-app: taide-binlog
-    spec:
-      hostAliases:
-        - ip: "172.16.101.16"
-          hostnames:
-            - "baidu06"
-        - ip: "172.16.101.17"
-          hostnames:
-            - "baidu07"
-        - ip: "172.16.101.18"
-          hostnames:
-            - "baidu08"
-        - ip: "172.16.101.19"
-          hostnames:
-            - "baidu09"
-      imagePullSecrets:
-        - name: registry-key
-      containers:
-        - command: [ "java","-cp","/app.jar","com.cxzx.canal.CanalClientMain","canal","taide-binlog" ]
-          env:
-            - name: PATH
-              value: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
-            - name: TZ
-              value: Asia/Shanghai
-          image: { { image } }
-          imagePullPolicy: IfNotPresent
-          name: taide-binlog
-          resources:
-            limits:
-              cpu: 100m
-              memory: 515Mi
-            requests:
-              cpu: 100m
-              memory: 50Mi
-      dnsPolicy: ClusterFirst
-      terminationGracePeriodSeconds: 10
-