Browse Source

编写k8s部署文件

lijie 3 years ago
parent
commit
16de858734
2 changed files with 52 additions and 62 deletions
  1. 22 31
      docker/k8sfiles/dmp-dic-standard.yml
  2. 30 31
      docker/k8sfiles/dmp-rwd-standard.yml

+ 22 - 31
docker/k8sfiles/dmp-dic-standard.yml

@@ -41,37 +41,28 @@ spec:
         - name: SERVER_PORT
           value: "8080"
         - name: SPRING_CLOUD_CONFIG_URI
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: spring.cloud.config.uri
+          value: "http://integrated-config:8080"
         - name: SPRING_PROFILES_ACTIVE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: spring.profiles.active
+          value: "dev"
         - name: SPRING_CLOUD_CONFIG_PROFILE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: spring.cloud.config.profile
-        - name: EUREKA_CLIENT_FETCH_REGISTRY
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: eureka.client.fetch-registry
-        - name: EUREKA_CLIENT_REGISTER_WITH_EUREKA
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: eureka.client.register-with-eureka
+          value: "dev"
         - name: EUREKA_CLIENT_DEFAULT_ZONE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: eureka.client.default.zone
-        - name: EUREKA_INSTANCE_IP_ADDRESS
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-dic
-              key: eureka.instance.ip.address
+          value: "http://frame:123456@integrated-eureka:8080/integrated-eureka/eureka/"
+        - name: logging.config
+          value: classpath:logback-spring.xml
+        - name: eureka.instance.status-page-url
+          value: "http://${eureka.instance.ip-address}:${eureka.instance.non-secure-port}/${spring.application.name}/info"
+        - name: eureka.instance.non-secure-port-enabled
+          value: "true"
+        - name: eureka.instance.ip-address
+          value: "dmp-dic"
+        - name: eureka.instance.health-check-url
+          value: "http://${eureka.instance.ip-address}:${eureka.instance.non-secure-port}/${spring.application.name}/health"
+        - name: eureka.instance.non-secure-port
+          value: "8080"
+        - name: persagy.common.auth.channel
+          value: "1"
+        - name: saas.ems.web.service
+          value: "http://ems-saas-web:8080"
+        - name: mybatis-plus.configuration.log-impl
+          value: "org.apache.ibatis.logging.nologging.NoLoggingImpl"

+ 30 - 31
docker/k8sfiles/dmp-rwd-standard.yml

@@ -41,37 +41,36 @@ spec:
         - name: SERVER_PORT
           value: "8080"
         - name: SPRING_CLOUD_CONFIG_URI
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: spring.cloud.config.uri
+          value: "http://integrated-config:8080"
         - name: SPRING_PROFILES_ACTIVE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: spring.profiles.active
+          value: "dev"
         - name: SPRING_CLOUD_CONFIG_PROFILE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: spring.cloud.config.profile
-        - name: EUREKA_CLIENT_FETCH_REGISTRY
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: eureka.client.fetch-registry
-        - name: EUREKA_CLIENT_REGISTER_WITH_EUREKA
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: eureka.client.register-with-eureka
+          value: "dev"
         - name: EUREKA_CLIENT_DEFAULT_ZONE
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: eureka.client.default.zone
-        - name: EUREKA_INSTANCE_IP_ADDRESS
-          valueFrom:
-            configMapKeyRef:
-              name: dmp-rwd
-              key: eureka.instance.ip.address
+          value: "http://frame:123456@integrated-eureka:8080/integrated-eureka/eureka/"
+        - name: logging.config
+          value: classpath:logback-spring.xml
+        - name: eureka.instance.status-page-url
+          value: "http://${eureka.instance.ip-address}:${eureka.instance.non-secure-port}/${spring.application.name}/info"
+        - name: eureka.instance.non-secure-port-enabled
+          value: "true"
+        - name: eureka.instance.ip-address
+          value: "dmp-rwd"
+        - name: eureka.instance.health-check-url
+          value: "http://${eureka.instance.ip-address}:${eureka.instance.non-secure-port}/${spring.application.name}/health"
+        - name: eureka.instance.non-secure-port
+          value: "8080"
+        - name: persagy.common.auth.channel
+          value: "1"
+        - name: saas.ems.web.service
+          value: "http://ems-saas-web:8080"
+        - name: mybatis-plus.configuration.log-impl
+          value: "org.apache.ibatis.logging.nologging.NoLoggingImpl"
+        volumeMounts:
+          - mountPath: /mnt/persagy/dmp-rwd/config/data.sql
+            name: nfs-pvc
+            subPath: dmp-rwd/data.sql
+      volumes:
+        - name: nfs-pvc
+          persistentVolumeClaim:
+            claimName: pv-oss-bdtp