From ba8ef5cd4d5fccfa2c25ec19aba58da999c0995d Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sat, 13 May 2023 20:00:10 -0500 Subject: [PATCH 01/13] Fix deployment, change java docker image, not longer in docker hub --- ts-admin-basic-info-service/Dockerfile | 2 +- ts-admin-order-service/Dockerfile | 2 +- ts-admin-route-service/Dockerfile | 2 +- ts-admin-travel-service/Dockerfile | 2 +- ts-admin-user-service/Dockerfile | 2 +- ts-assurance-service/Dockerfile | 2 +- ts-auth-service/Dockerfile | 2 +- ts-basic-service/Dockerfile | 2 +- ts-cancel-service/Dockerfile | 2 +- ts-config-service/Dockerfile | 2 +- ts-consign-price-service/Dockerfile | 2 +- ts-consign-service/Dockerfile | 2 +- ts-contacts-service/Dockerfile | 2 +- ts-delivery-service/Dockerfile | 2 +- ts-execute-service/Dockerfile | 2 +- ts-food-delivery-service/Dockerfile | 2 +- ts-food-service/Dockerfile | 2 +- ts-gateway-service/Dockerfile | 2 +- ts-inside-payment-service/Dockerfile | 2 +- ts-notification-service/Dockerfile | 2 +- ts-order-other-service/Dockerfile | 2 +- ts-order-service/Dockerfile | 2 +- ts-payment-service/Dockerfile | 2 +- ts-preserve-other-service/Dockerfile | 2 +- ts-preserve-service/Dockerfile | 2 +- ts-price-service/Dockerfile | 2 +- ts-rebook-service/Dockerfile | 2 +- ts-route-plan-service/Dockerfile | 2 +- ts-route-service/Dockerfile | 2 +- ts-seat-service/Dockerfile | 2 +- ts-security-service/Dockerfile | 2 +- ts-station-food-service/Dockerfile | 2 +- ts-station-service/Dockerfile | 2 +- ts-train-food-service/Dockerfile | 2 +- ts-train-service/Dockerfile | 2 +- ts-travel-plan-service/Dockerfile | 2 +- ts-travel-service/Dockerfile | 2 +- ts-travel2-service/Dockerfile | 2 +- ts-user-service/Dockerfile | 2 +- ts-verification-code-service/Dockerfile | 2 +- ts-wait-order-service/Dockerfile | 2 +- 41 files changed, 41 insertions(+), 41 deletions(-) diff --git a/ts-admin-basic-info-service/Dockerfile b/ts-admin-basic-info-service/Dockerfile index 3862d1c70..ca4350f30 100644 --- a/ts-admin-basic-info-service/Dockerfile +++ b/ts-admin-basic-info-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-admin-order-service/Dockerfile b/ts-admin-order-service/Dockerfile index ce0b649b9..01850d9fe 100644 --- a/ts-admin-order-service/Dockerfile +++ b/ts-admin-order-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-admin-route-service/Dockerfile b/ts-admin-route-service/Dockerfile index 0b818ba32..1af139810 100644 --- a/ts-admin-route-service/Dockerfile +++ b/ts-admin-route-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-admin-travel-service/Dockerfile b/ts-admin-travel-service/Dockerfile index fd4044fd6..2c3b9b476 100644 --- a/ts-admin-travel-service/Dockerfile +++ b/ts-admin-travel-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-admin-user-service/Dockerfile b/ts-admin-user-service/Dockerfile index 78d3dcd2f..b4a5d537f 100644 --- a/ts-admin-user-service/Dockerfile +++ b/ts-admin-user-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-assurance-service/Dockerfile b/ts-assurance-service/Dockerfile index 6991cfd7e..7cad5cf37 100644 --- a/ts-assurance-service/Dockerfile +++ b/ts-assurance-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-auth-service/Dockerfile b/ts-auth-service/Dockerfile index cbc06d73b..c61210aa9 100644 --- a/ts-auth-service/Dockerfile +++ b/ts-auth-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-basic-service/Dockerfile b/ts-basic-service/Dockerfile index 44045e159..ef58bb937 100644 --- a/ts-basic-service/Dockerfile +++ b/ts-basic-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-cancel-service/Dockerfile b/ts-cancel-service/Dockerfile index e553e76c0..f4d610879 100644 --- a/ts-cancel-service/Dockerfile +++ b/ts-cancel-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-config-service/Dockerfile b/ts-config-service/Dockerfile index dd9aaba1c..cdea430d2 100644 --- a/ts-config-service/Dockerfile +++ b/ts-config-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-consign-price-service/Dockerfile b/ts-consign-price-service/Dockerfile index 1d7c87766..cbd348a5c 100644 --- a/ts-consign-price-service/Dockerfile +++ b/ts-consign-price-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-consign-service/Dockerfile b/ts-consign-service/Dockerfile index d592b2afb..4d8237d19 100644 --- a/ts-consign-service/Dockerfile +++ b/ts-consign-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-contacts-service/Dockerfile b/ts-contacts-service/Dockerfile index 35be04a09..ad0199240 100644 --- a/ts-contacts-service/Dockerfile +++ b/ts-contacts-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-delivery-service/Dockerfile b/ts-delivery-service/Dockerfile index 619afbee4..1d55bbbc1 100644 --- a/ts-delivery-service/Dockerfile +++ b/ts-delivery-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-execute-service/Dockerfile b/ts-execute-service/Dockerfile index b97ab4739..404043cd3 100644 --- a/ts-execute-service/Dockerfile +++ b/ts-execute-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-food-delivery-service/Dockerfile b/ts-food-delivery-service/Dockerfile index fcca1fb4a..28f555f7a 100644 --- a/ts-food-delivery-service/Dockerfile +++ b/ts-food-delivery-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-food-service/Dockerfile b/ts-food-service/Dockerfile index bf68dd49c..114a71714 100644 --- a/ts-food-service/Dockerfile +++ b/ts-food-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-gateway-service/Dockerfile b/ts-gateway-service/Dockerfile index 3468588f2..0eed855b8 100644 --- a/ts-gateway-service/Dockerfile +++ b/ts-gateway-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-inside-payment-service/Dockerfile b/ts-inside-payment-service/Dockerfile index 2b4cc4523..7ca5ebe8c 100644 --- a/ts-inside-payment-service/Dockerfile +++ b/ts-inside-payment-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-notification-service/Dockerfile b/ts-notification-service/Dockerfile index b1d835884..549c02802 100644 --- a/ts-notification-service/Dockerfile +++ b/ts-notification-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-order-other-service/Dockerfile b/ts-order-other-service/Dockerfile index e53ed542a..ef9491f36 100644 --- a/ts-order-other-service/Dockerfile +++ b/ts-order-other-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-order-service/Dockerfile b/ts-order-service/Dockerfile index da8c10924..4f6e58251 100644 --- a/ts-order-service/Dockerfile +++ b/ts-order-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-payment-service/Dockerfile b/ts-payment-service/Dockerfile index fa20f2bf6..b26378a63 100644 --- a/ts-payment-service/Dockerfile +++ b/ts-payment-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-preserve-other-service/Dockerfile b/ts-preserve-other-service/Dockerfile index 6f1fac7e3..920cf55c0 100644 --- a/ts-preserve-other-service/Dockerfile +++ b/ts-preserve-other-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-preserve-service/Dockerfile b/ts-preserve-service/Dockerfile index cf9785e87..b3a7be772 100644 --- a/ts-preserve-service/Dockerfile +++ b/ts-preserve-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-price-service/Dockerfile b/ts-price-service/Dockerfile index 0c994fc0e..1e0269b13 100644 --- a/ts-price-service/Dockerfile +++ b/ts-price-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-rebook-service/Dockerfile b/ts-rebook-service/Dockerfile index 79868eca0..4a9109d23 100644 --- a/ts-rebook-service/Dockerfile +++ b/ts-rebook-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-route-plan-service/Dockerfile b/ts-route-plan-service/Dockerfile index ffdb504c8..ca4ac0677 100644 --- a/ts-route-plan-service/Dockerfile +++ b/ts-route-plan-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-route-service/Dockerfile b/ts-route-service/Dockerfile index 5327d62e7..940bad6f8 100644 --- a/ts-route-service/Dockerfile +++ b/ts-route-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-seat-service/Dockerfile b/ts-seat-service/Dockerfile index 92128650a..83a2f32c4 100644 --- a/ts-seat-service/Dockerfile +++ b/ts-seat-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-security-service/Dockerfile b/ts-security-service/Dockerfile index cd6b723b8..6825d1c1a 100644 --- a/ts-security-service/Dockerfile +++ b/ts-security-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-station-food-service/Dockerfile b/ts-station-food-service/Dockerfile index 0fc92f341..4c9b78c30 100644 --- a/ts-station-food-service/Dockerfile +++ b/ts-station-food-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-station-service/Dockerfile b/ts-station-service/Dockerfile index 9b9597390..00aa14789 100644 --- a/ts-station-service/Dockerfile +++ b/ts-station-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-train-food-service/Dockerfile b/ts-train-food-service/Dockerfile index de3c56173..5ee2c998d 100644 --- a/ts-train-food-service/Dockerfile +++ b/ts-train-food-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-train-service/Dockerfile b/ts-train-service/Dockerfile index 6ac50c626..dca976b9c 100644 --- a/ts-train-service/Dockerfile +++ b/ts-train-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-travel-plan-service/Dockerfile b/ts-travel-plan-service/Dockerfile index 414cf5ff0..ae28dff03 100644 --- a/ts-travel-plan-service/Dockerfile +++ b/ts-travel-plan-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-travel-service/Dockerfile b/ts-travel-service/Dockerfile index 87c3aa255..b5157fc04 100644 --- a/ts-travel-service/Dockerfile +++ b/ts-travel-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-travel2-service/Dockerfile b/ts-travel2-service/Dockerfile index 6609a14bc..bce03eeda 100644 --- a/ts-travel2-service/Dockerfile +++ b/ts-travel2-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-user-service/Dockerfile b/ts-user-service/Dockerfile index f3835c3ce..de796efc9 100644 --- a/ts-user-service/Dockerfile +++ b/ts-user-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-verification-code-service/Dockerfile b/ts-verification-code-service/Dockerfile index c797703fd..ae0c44bb4 100644 --- a/ts-verification-code-service/Dockerfile +++ b/ts-verification-code-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone diff --git a/ts-wait-order-service/Dockerfile b/ts-wait-order-service/Dockerfile index 5b88a2863..0791a9c5a 100644 --- a/ts-wait-order-service/Dockerfile +++ b/ts-wait-order-service/Dockerfile @@ -1,4 +1,4 @@ -FROM java:8-jre +FROM eclipse-temurin:8-jre RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone From 417687e915e362f40e5a076c4934238c98e48a8c Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sat, 13 May 2023 20:02:17 -0500 Subject: [PATCH 02/13] Fix deployment, avatar-srv does not work with latest python --- ts-avatar-service/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ts-avatar-service/Dockerfile b/ts-avatar-service/Dockerfile index 715a1c39c..ea154af7a 100644 --- a/ts-avatar-service/Dockerfile +++ b/ts-avatar-service/Dockerfile @@ -1,4 +1,4 @@ -FROM python:3 +FROM python:3.9.6 RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone From 5820899d94e21fb85c4d73a1d8884c31ae495c61 Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sat, 13 May 2023 20:05:13 -0500 Subject: [PATCH 03/13] Upgrade version to 1.0.1 --- .../quickstart-k8s/charts/mysql/Chart.yaml | 2 +- .../quickstart-k8s/yamls/deploy.yaml.sample | 70 +++++++++---------- .../yamls/sw_deploy.yaml.sample | 70 +++++++++---------- 3 files changed, 71 insertions(+), 71 deletions(-) diff --git a/deployment/kubernetes-manifests/quickstart-k8s/charts/mysql/Chart.yaml b/deployment/kubernetes-manifests/quickstart-k8s/charts/mysql/Chart.yaml index c9b10c7f6..f8265ce16 100644 --- a/deployment/kubernetes-manifests/quickstart-k8s/charts/mysql/Chart.yaml +++ b/deployment/kubernetes-manifests/quickstart-k8s/charts/mysql/Chart.yaml @@ -16,7 +16,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.0 +version: 1.0.1 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml.sample b/deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml.sample index 89aa4c889..79ea0549e 100644 --- a/deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml.sample +++ b/deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml.sample @@ -14,7 +14,7 @@ spec: spec: containers: - name: ts-admin-basic-info-service - image: codewisdom/ts-admin-basic-info-service:1.0.0 + image: codewisdom/ts-admin-basic-info-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -98,7 +98,7 @@ spec: spec: containers: - name: ts-admin-route-service - image: codewisdom/ts-admin-route-service:1.0.0 + image: codewisdom/ts-admin-route-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -140,7 +140,7 @@ spec: spec: containers: - name: ts-admin-travel-service - image: codewisdom/ts-admin-travel-service:1.0.0 + image: codewisdom/ts-admin-travel-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -224,7 +224,7 @@ spec: spec: containers: - name: ts-assurance-service - image: codewisdom/ts-assurance-service:1.0.0 + image: codewisdom/ts-assurance-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -268,7 +268,7 @@ spec: spec: containers: - name: ts-auth-service - image: codewisdom/ts-auth-service:1.0.0 + image: codewisdom/ts-auth-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -354,7 +354,7 @@ spec: spec: containers: - name: ts-basic-service - image: codewisdom/ts-basic-service:1.0.0 + image: codewisdom/ts-basic-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -396,7 +396,7 @@ spec: spec: containers: - name: ts-cancel-service - image: codewisdom/ts-cancel-service:1.0.0 + image: codewisdom/ts-cancel-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -438,7 +438,7 @@ spec: spec: containers: - name: ts-config-service - image: codewisdom/ts-config-service:1.0.0 + image: codewisdom/ts-config-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -482,7 +482,7 @@ spec: spec: containers: - name: ts-consign-price-service - image: codewisdom/ts-consign-price-service:1.0.0 + image: codewisdom/ts-consign-price-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -570,7 +570,7 @@ spec: spec: containers: - name: ts-contacts-service - image: codewisdom/ts-contacts-service:1.0.0 + image: codewisdom/ts-contacts-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -614,7 +614,7 @@ spec: spec: containers: - name: ts-delivery-service - image: codewisdom/ts-delivery-service:1.0.0 + image: codewisdom/ts-delivery-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -660,7 +660,7 @@ spec: spec: containers: - name: ts-execute-service - image: codewisdom/ts-execute-service:1.0.0 + image: codewisdom/ts-execute-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -702,7 +702,7 @@ spec: spec: containers: - name: ts-food-service - image: codewisdom/ts-food-service:1.0.0 + image: codewisdom/ts-food-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -748,7 +748,7 @@ spec: spec: containers: - name: ts-food-delivery-service - image: codewisdom/ts-food-delivery-service:1.0.0 + image: codewisdom/ts-food-delivery-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -792,7 +792,7 @@ spec: spec: containers: - name: ts-gateway-service - image: codewisdom/ts-gateway-service:1.0.0 + image: codewisdom/ts-gateway-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -834,7 +834,7 @@ spec: spec: containers: - name: ts-inside-payment-service - image: codewisdom/ts-inside-payment-service:1.0.0 + image: codewisdom/ts-inside-payment-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -878,7 +878,7 @@ spec: spec: containers: - name: ts-news-service - image: codewisdom/ts-news-service:1.0.0 + image: codewisdom/ts-news-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -920,7 +920,7 @@ spec: spec: containers: - name: ts-notification-service - image: codewisdom/ts-notification-service:1.0.0 + image: codewisdom/ts-notification-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1058,7 +1058,7 @@ spec: spec: containers: - name: ts-payment-service - image: codewisdom/ts-payment-service:1.0.0 + image: codewisdom/ts-payment-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1102,7 +1102,7 @@ spec: spec: containers: - name: ts-preserve-other-service - image: codewisdom/ts-preserve-other-service:1.0.0 + image: codewisdom/ts-preserve-other-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1146,7 +1146,7 @@ spec: spec: containers: - name: ts-preserve-service - image: codewisdom/ts-preserve-service:1.0.0 + image: codewisdom/ts-preserve-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1190,7 +1190,7 @@ spec: spec: containers: - name: ts-price-service - image: codewisdom/ts-price-service:1.0.0 + image: codewisdom/ts-price-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1278,7 +1278,7 @@ spec: spec: containers: - name: ts-route-plan-service - image: codewisdom/ts-route-plan-service:1.0.0 + image: codewisdom/ts-route-plan-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1320,7 +1320,7 @@ spec: spec: containers: - name: ts-route-service - image: codewisdom/ts-route-service:1.0.0 + image: codewisdom/ts-route-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1364,7 +1364,7 @@ spec: spec: containers: - name: ts-seat-service - image: codewisdom/ts-seat-service:1.0.0 + image: codewisdom/ts-seat-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1406,7 +1406,7 @@ spec: spec: containers: - name: ts-security-service - image: codewisdom/ts-security-service:1.0.0 + image: codewisdom/ts-security-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1450,7 +1450,7 @@ spec: spec: containers: - name: ts-station-food-service - image: codewisdom/ts-station-food-service:1.0.0 + image: codewisdom/ts-station-food-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1538,7 +1538,7 @@ spec: spec: containers: - name: ts-ticket-office-service - image: codewisdom/ts-ticket-office-service:1.0.0 + image: codewisdom/ts-ticket-office-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1582,7 +1582,7 @@ spec: spec: containers: - name: ts-train-food-service - image: codewisdom/ts-train-food-service:1.0.0 + image: codewisdom/ts-train-food-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1626,7 +1626,7 @@ spec: spec: containers: - name: ts-train-service - image: codewisdom/ts-train-service:1.0.0 + image: codewisdom/ts-train-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1670,7 +1670,7 @@ spec: spec: containers: - name: ts-travel-plan-service - image: codewisdom/ts-travel-plan-service:1.0.0 + image: codewisdom/ts-travel-plan-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1712,7 +1712,7 @@ spec: spec: containers: - name: ts-travel-service - image: codewisdom/ts-travel-service:1.0.0 + image: codewisdom/ts-travel-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1756,7 +1756,7 @@ spec: spec: containers: - name: ts-travel2-service - image: codewisdom/ts-travel2-service:1.0.0 + image: codewisdom/ts-travel2-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1844,7 +1844,7 @@ spec: spec: containers: - name: ts-verification-code-service - image: codewisdom/ts-verification-code-service:1.0.0 + image: codewisdom/ts-verification-code-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP @@ -1886,7 +1886,7 @@ spec: spec: containers: - name: ts-voucher-service - image: codewisdom/ts-voucher-service:1.0.0 + image: codewisdom/ts-voucher-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP diff --git a/deployment/kubernetes-manifests/quickstart-k8s/yamls/sw_deploy.yaml.sample b/deployment/kubernetes-manifests/quickstart-k8s/yamls/sw_deploy.yaml.sample index 13764f16b..a0a94ae8b 100644 --- a/deployment/kubernetes-manifests/quickstart-k8s/yamls/sw_deploy.yaml.sample +++ b/deployment/kubernetes-manifests/quickstart-k8s/yamls/sw_deploy.yaml.sample @@ -25,7 +25,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-admin-basic-info-service - image: codewisdom/ts-admin-basic-info-service:1.0.0 + image: codewisdom/ts-admin-basic-info-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -161,7 +161,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-admin-route-service - image: codewisdom/ts-admin-route-service:1.0.0 + image: codewisdom/ts-admin-route-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -229,7 +229,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-admin-travel-service - image: codewisdom/ts-admin-travel-service:1.0.0 + image: codewisdom/ts-admin-travel-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -365,7 +365,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-assurance-service - image: codewisdom/ts-assurance-service:1.0.0 + image: codewisdom/ts-assurance-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -435,7 +435,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-auth-service - image: codewisdom/ts-auth-service:1.0.0 + image: codewisdom/ts-auth-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -573,7 +573,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-basic-service - image: codewisdom/ts-basic-service:1.0.0 + image: codewisdom/ts-basic-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -641,7 +641,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-cancel-service - image: codewisdom/ts-cancel-service:1.0.0 + image: codewisdom/ts-cancel-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -709,7 +709,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-config-service - image: codewisdom/ts-config-service:1.0.0 + image: codewisdom/ts-config-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -779,7 +779,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-consign-price-service - image: codewisdom/ts-consign-price-service:1.0.0 + image: codewisdom/ts-consign-price-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -919,7 +919,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-contacts-service - image: codewisdom/ts-contacts-service:1.0.0 + image: codewisdom/ts-contacts-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -989,7 +989,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-delivery-service - image: codewisdom/ts-delivery-service:1.0.0 + image: codewisdom/ts-delivery-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1061,7 +1061,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-execute-service - image: codewisdom/ts-execute-service:1.0.0 + image: codewisdom/ts-execute-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1129,7 +1129,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-food-delivery-service - image: codewisdom/ts-food-delivery-service:1.0.0 + image: codewisdom/ts-food-delivery-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1199,7 +1199,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-food-service - image: codewisdom/ts-food-service:1.0.0 + image: codewisdom/ts-food-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1271,7 +1271,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-gateway-service - image: codewisdom/ts-gateway-service:1.0.0 + image: codewisdom/ts-gateway-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1339,7 +1339,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-inside-payment-service - image: codewisdom/ts-inside-payment-service:1.0.0 + image: codewisdom/ts-inside-payment-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1409,7 +1409,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-news-service - image: codewisdom/ts-news-service:1.0.0 + image: codewisdom/ts-news-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1477,7 +1477,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-notification-service - image: codewisdom/ts-notification-service:1.0.0 + image: codewisdom/ts-notification-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1693,7 +1693,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-payment-service - image: codewisdom/ts-payment-service:1.0.0 + image: codewisdom/ts-payment-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1763,7 +1763,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-preserve-other-service - image: codewisdom/ts-preserve-other-service:1.0.0 + image: codewisdom/ts-preserve-other-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1833,7 +1833,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-preserve-service - image: codewisdom/ts-preserve-service:1.0.0 + image: codewisdom/ts-preserve-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -1903,7 +1903,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-price-service - image: codewisdom/ts-price-service:1.0.0 + image: codewisdom/ts-price-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2043,7 +2043,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-route-plan-service - image: codewisdom/ts-route-plan-service:1.0.0 + image: codewisdom/ts-route-plan-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2111,7 +2111,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-route-service - image: codewisdom/ts-route-service:1.0.0 + image: codewisdom/ts-route-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2181,7 +2181,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-seat-service - image: codewisdom/ts-seat-service:1.0.0 + image: codewisdom/ts-seat-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2249,7 +2249,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-security-service - image: codewisdom/ts-security-service:1.0.0 + image: codewisdom/ts-security-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2319,7 +2319,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-station-food-service - image: codewisdom/ts-station-food-service:1.0.0 + image: codewisdom/ts-station-food-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2459,7 +2459,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-ticket-office-service - image: codewisdom/ts-ticket-office-service:1.0.0 + image: codewisdom/ts-ticket-office-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2529,7 +2529,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-train-food-service - image: codewisdom/ts-train-food-service:1.0.0 + image: codewisdom/ts-train-food-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2599,7 +2599,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-train-service - image: codewisdom/ts-train-service:1.0.0 + image: codewisdom/ts-train-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2669,7 +2669,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-travel-plan-service - image: codewisdom/ts-travel-plan-service:1.0.0 + image: codewisdom/ts-travel-plan-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2737,7 +2737,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-travel-service - image: codewisdom/ts-travel-service:1.0.0 + image: codewisdom/ts-travel-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2807,7 +2807,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-travel2-service - image: codewisdom/ts-travel2-service:1.0.0 + image: codewisdom/ts-travel2-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -2947,7 +2947,7 @@ spec: args: [ "-c", "cp -R /skywalking/agent /agent/" ] containers: - name: ts-verification-code-service - image: codewisdom/ts-verification-code-service:1.0.0 + image: codewisdom/ts-verification-code-service:1.0.1 imagePullPolicy: IfNotPresent volumeMounts: - name: skywalking-agent @@ -3004,7 +3004,7 @@ spec: spec: containers: - name: ts-voucher-service - image: codewisdom/ts-voucher-service:1.0.0 + image: codewisdom/ts-voucher-service:1.0.1 imagePullPolicy: IfNotPresent env: - name: NODE_IP From 34cdb902ee29b6439f3f0979185ce1f89084a883 Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sun, 14 May 2023 11:32:46 -0500 Subject: [PATCH 04/13] Set .sh eol --- .gitattributes | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 000000000..70a0dde0b --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +* text=auto +*.sh text eol=lf From 694e44523707fa5af6b30a3d7d1e6abf271aa28a Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sun, 14 May 2023 11:36:28 -0500 Subject: [PATCH 05/13] Set latest tag by default in makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 24ceab756..8ba6f3f79 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # Codewisdom Train-Ticket system Repo=codewisdom -Tag=latest +Tag=1.0.1 Namespace="default" DeployArgs="" From c992d8f36a730542c8fbe35aabafb0437e0f9061 Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sun, 14 May 2023 11:39:28 -0500 Subject: [PATCH 06/13] make deploy by default built from source code --- Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 8ba6f3f79..a092fa226 100644 --- a/Makefile +++ b/Makefile @@ -27,14 +27,18 @@ push-image: publish-image: @script/publish-docker-images.sh $(Repo) $(Tag) +# deploy from source +.PHONY: deploy +deploy: build deploy-no-build + # deploy # DeployArgs "" : deploy train-ticket with all-in-one mysql cluster # DeployArgs "--independent-db" : deploy train-ticket with mysql cluster each service # DeployArgs "--with-monitoring" : deploy train-ticket with prometheus # DeployArgs "--with-tracing" : deploy train-ticket with skywalking # DeployArgs "--all" : deploy train-ticket with mysql cluster each service -.PHONY: deploy -deploy: +.PHONY: deploy-no-build +deploy-no-build: @hack/deploy/deploy.sh $(Namespace) "$(DeployArgs)" # deploy From 257e0752d3fbbc214b0d08eec85660a3269b41bd Mon Sep 17 00:00:00 2001 From: Jorge Yero Salazar Date: Sun, 14 May 2023 12:16:16 -0500 Subject: [PATCH 07/13] Build java jar inside docker --- Makefile | 6 +----- hack/build-image.sh | 2 +- script/publish-docker-images.sh | 2 +- ts-admin-basic-info-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-admin-order-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-admin-route-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-admin-travel-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-admin-user-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-assurance-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-auth-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-avatar-service/Dockerfile | 2 +- ts-basic-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-cancel-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-config-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-consign-price-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-consign-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-contacts-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-delivery-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-execute-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-food-delivery-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-food-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-gateway-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-inside-payment-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-news-service/Dockerfile | 2 +- ts-notification-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-order-other-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-order-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-payment-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-preserve-other-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-preserve-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-price-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-rebook-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-route-plan-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-route-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-seat-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-security-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-station-food-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-station-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-ticket-office-service/Dockerfile | 10 +++++----- ts-train-food-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-train-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-travel-plan-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-travel-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-travel2-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-ui-dashboard/Dockerfile | 4 ++-- ts-user-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-verification-code-service/Dockerfile | 25 +++++++++++++++++++++++-- ts-voucher-service/Dockerfile | 4 ++-- ts-wait-order-service/Dockerfile | 25 +++++++++++++++++++++++-- 49 files changed, 957 insertions(+), 100 deletions(-) diff --git a/Makefile b/Makefile index a092fa226..ff71610c2 100644 --- a/Makefile +++ b/Makefile @@ -8,11 +8,7 @@ DeployArgs="" # build image .PHONY: build -build: clean-image package build-image - -.PHONY: package -package: - @mvn clean package -Dmaven.test.skip=true +build: clean-image build-image .PHONY: build-image build-image: diff --git a/hack/build-image.sh b/hack/build-image.sh index f5fa56160..216765db8 100755 --- a/hack/build-image.sh +++ b/hack/build-image.sh @@ -8,7 +8,7 @@ for dir in ts-*; do if [[ -d $dir ]]; then if [[ -n $(ls "$dir" | grep -i Dockerfile) ]]; then echo "build ${dir}" - docker build -t "$1"/"${dir}" "$dir" + docker build -t "$1"/"${dir}" -f "${dir}/Dockerfile" "." docker tag "$1"/"${dir}":latest "$1"/"${dir}":"$2" fi fi diff --git a/script/publish-docker-images.sh b/script/publish-docker-images.sh index 4802a7ede..1970d1ead 100755 --- a/script/publish-docker-images.sh +++ b/script/publish-docker-images.sh @@ -9,7 +9,7 @@ for dir in ts-*; do if [[ -n $(ls "$dir" | grep -i Dockerfile) ]]; then echo "build ${dir}" # Must use `buildx` as docker build tool - docker build --push -t "$1"/"${dir}":"$2" "$dir" + docker build --push -t "$1"/"${dir}":"$2" -f "${dir}/Dockerfile" "." fi fi done diff --git a/ts-admin-basic-info-service/Dockerfile b/ts-admin-basic-info-service/Dockerfile index ca4350f30..8dade4bcf 100644 --- a/ts-admin-basic-info-service/Dockerfile +++ b/ts-admin-basic-info-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-admin-basic-info-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-admin-basic-info-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-admin-basic-info-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-admin-basic-info-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18767 \ No newline at end of file diff --git a/ts-admin-order-service/Dockerfile b/ts-admin-order-service/Dockerfile index 01850d9fe..d7bec2350 100644 --- a/ts-admin-order-service/Dockerfile +++ b/ts-admin-order-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-admin-order-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-admin-order-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-admin-order-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-admin-order-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16112 \ No newline at end of file diff --git a/ts-admin-route-service/Dockerfile b/ts-admin-route-service/Dockerfile index 1af139810..78c039258 100644 --- a/ts-admin-route-service/Dockerfile +++ b/ts-admin-route-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-admin-route-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-admin-route-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-admin-route-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-admin-route-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16113 \ No newline at end of file diff --git a/ts-admin-travel-service/Dockerfile b/ts-admin-travel-service/Dockerfile index 2c3b9b476..e69c254c5 100644 --- a/ts-admin-travel-service/Dockerfile +++ b/ts-admin-travel-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-admin-travel-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-admin-travel-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-admin-travel-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-admin-travel-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16114 \ No newline at end of file diff --git a/ts-admin-user-service/Dockerfile b/ts-admin-user-service/Dockerfile index b4a5d537f..de344fcd8 100644 --- a/ts-admin-user-service/Dockerfile +++ b/ts-admin-user-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-admin-user-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-admin-user-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-admin-user-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-admin-user-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16115 \ No newline at end of file diff --git a/ts-assurance-service/Dockerfile b/ts-assurance-service/Dockerfile index 7cad5cf37..f3885d238 100644 --- a/ts-assurance-service/Dockerfile +++ b/ts-assurance-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-assurance-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-assurance-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-assurance-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-assurance-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18888 \ No newline at end of file diff --git a/ts-auth-service/Dockerfile b/ts-auth-service/Dockerfile index c61210aa9..9732b8c03 100644 --- a/ts-auth-service/Dockerfile +++ b/ts-auth-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-auth-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-auth-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-auth-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-auth-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12349 \ No newline at end of file diff --git a/ts-avatar-service/Dockerfile b/ts-avatar-service/Dockerfile index ea154af7a..862c24c36 100644 --- a/ts-avatar-service/Dockerfile +++ b/ts-avatar-service/Dockerfile @@ -9,7 +9,7 @@ RUN apt install -y libgl1-mesa-glx ENV PYTHONUNBUFFERED=TRUE RUN mkdir -p /app -ADD . /app/ +ADD ts-avatar-service /app/ WORKDIR /app RUN pip install -r requirements.txt diff --git a/ts-basic-service/Dockerfile b/ts-basic-service/Dockerfile index ef58bb937..8e1c53cb1 100644 --- a/ts-basic-service/Dockerfile +++ b/ts-basic-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-basic-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-basic-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-basic-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-basic-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 15680 \ No newline at end of file diff --git a/ts-cancel-service/Dockerfile b/ts-cancel-service/Dockerfile index f4d610879..fcf140f21 100644 --- a/ts-cancel-service/Dockerfile +++ b/ts-cancel-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-cancel-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-cancel-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-cancel-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-cancel-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18885 \ No newline at end of file diff --git a/ts-config-service/Dockerfile b/ts-config-service/Dockerfile index cdea430d2..3f32942ff 100644 --- a/ts-config-service/Dockerfile +++ b/ts-config-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-config-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-config-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-config-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-config-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 15679 \ No newline at end of file diff --git a/ts-consign-price-service/Dockerfile b/ts-consign-price-service/Dockerfile index cbd348a5c..00beccb27 100644 --- a/ts-consign-price-service/Dockerfile +++ b/ts-consign-price-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-consign-price-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-consign-price-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-consign-price-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-consign-price-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16110 \ No newline at end of file diff --git a/ts-consign-service/Dockerfile b/ts-consign-service/Dockerfile index 4d8237d19..3f63611ea 100644 --- a/ts-consign-service/Dockerfile +++ b/ts-consign-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-consign-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-consign-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-consign-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-consign-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16111 \ No newline at end of file diff --git a/ts-contacts-service/Dockerfile b/ts-contacts-service/Dockerfile index ad0199240..9132f5b49 100644 --- a/ts-contacts-service/Dockerfile +++ b/ts-contacts-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-contacts-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-contacts-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-contacts-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-contacts-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12347 \ No newline at end of file diff --git a/ts-delivery-service/Dockerfile b/ts-delivery-service/Dockerfile index 1d55bbbc1..7f3d7e331 100644 --- a/ts-delivery-service/Dockerfile +++ b/ts-delivery-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-delivery-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-delivery-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-delivery-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-delivery-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18856 diff --git a/ts-execute-service/Dockerfile b/ts-execute-service/Dockerfile index 404043cd3..788a0e1b9 100644 --- a/ts-execute-service/Dockerfile +++ b/ts-execute-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-execute-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-execute-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-execute-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-execute-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12386 \ No newline at end of file diff --git a/ts-food-delivery-service/Dockerfile b/ts-food-delivery-service/Dockerfile index 28f555f7a..c68f5a7de 100644 --- a/ts-food-delivery-service/Dockerfile +++ b/ts-food-delivery-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-food-delivery-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-food-delivery-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-food-delivery-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-food-delivery-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18957 diff --git a/ts-food-service/Dockerfile b/ts-food-service/Dockerfile index 114a71714..bcf06b215 100644 --- a/ts-food-service/Dockerfile +++ b/ts-food-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-food-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-food-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-food-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-food-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18856 \ No newline at end of file diff --git a/ts-gateway-service/Dockerfile b/ts-gateway-service/Dockerfile index 0eed855b8..66a308389 100644 --- a/ts-gateway-service/Dockerfile +++ b/ts-gateway-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-gateway-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-gateway-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-gateway-service-1.0.jar /app/ -CMD ["java", "-Xmx1024m", "-jar", "/app/ts-gateway-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx1024m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18888 diff --git a/ts-inside-payment-service/Dockerfile b/ts-inside-payment-service/Dockerfile index 7ca5ebe8c..2bc0998b4 100644 --- a/ts-inside-payment-service/Dockerfile +++ b/ts-inside-payment-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-inside-payment-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-inside-payment-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-inside-payment-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-inside-payment-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18673 \ No newline at end of file diff --git a/ts-news-service/Dockerfile b/ts-news-service/Dockerfile index e8a4a5805..2dfa6be21 100644 --- a/ts-news-service/Dockerfile +++ b/ts-news-service/Dockerfile @@ -4,7 +4,7 @@ FROM mrrm/web.go RUN mkdir -p /app WORKDIR /app -ADD ./src/main/main.go /app/ +ADD ./ts-news-service/src/main/main.go /app/ RUN go build CMD [ "./app" ] diff --git a/ts-notification-service/Dockerfile b/ts-notification-service/Dockerfile index 549c02802..4cceee0c9 100644 --- a/ts-notification-service/Dockerfile +++ b/ts-notification-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-notification-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-notification-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-notification-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-notification-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 17853 \ No newline at end of file diff --git a/ts-order-other-service/Dockerfile b/ts-order-other-service/Dockerfile index ef9491f36..866385845 100644 --- a/ts-order-other-service/Dockerfile +++ b/ts-order-other-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-order-other-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-order-other-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-order-other-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-order-other-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar #CMD java $JAVA_OPTIONS -jar /app/ts-order-other-service-1.0.jar EXPOSE 12032 \ No newline at end of file diff --git a/ts-order-service/Dockerfile b/ts-order-service/Dockerfile index 4f6e58251..24567d90a 100644 --- a/ts-order-service/Dockerfile +++ b/ts-order-service/Dockerfile @@ -1,9 +1,30 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-order-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-order-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-order-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-order-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar #CMD java $JAVA_OPTIONS -jar /app/ts-order-service-1.0.jar EXPOSE 12031 \ No newline at end of file diff --git a/ts-payment-service/Dockerfile b/ts-payment-service/Dockerfile index b26378a63..84d1eef38 100644 --- a/ts-payment-service/Dockerfile +++ b/ts-payment-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-payment-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-payment-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-payment-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-payment-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 19001 \ No newline at end of file diff --git a/ts-preserve-other-service/Dockerfile b/ts-preserve-other-service/Dockerfile index 920cf55c0..fdd5de637 100644 --- a/ts-preserve-other-service/Dockerfile +++ b/ts-preserve-other-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-preserve-other-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-preserve-other-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-preserve-other-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-preserve-other-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 14569 \ No newline at end of file diff --git a/ts-preserve-service/Dockerfile b/ts-preserve-service/Dockerfile index b3a7be772..b34cb8278 100644 --- a/ts-preserve-service/Dockerfile +++ b/ts-preserve-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-preserve-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-preserve-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-preserve-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-preserve-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 14568 \ No newline at end of file diff --git a/ts-price-service/Dockerfile b/ts-price-service/Dockerfile index 1e0269b13..e20f266a0 100644 --- a/ts-price-service/Dockerfile +++ b/ts-price-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-price-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-price-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-price-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-price-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16579 \ No newline at end of file diff --git a/ts-rebook-service/Dockerfile b/ts-rebook-service/Dockerfile index 4a9109d23..4b935dc58 100644 --- a/ts-rebook-service/Dockerfile +++ b/ts-rebook-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-rebook-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-rebook-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-rebook-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-rebook-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18886 \ No newline at end of file diff --git a/ts-route-plan-service/Dockerfile b/ts-route-plan-service/Dockerfile index ca4ac0677..c3c0c0e82 100644 --- a/ts-route-plan-service/Dockerfile +++ b/ts-route-plan-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-route-plan-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-route-plan-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-route-plan-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-route-plan-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 14578 \ No newline at end of file diff --git a/ts-route-service/Dockerfile b/ts-route-service/Dockerfile index 940bad6f8..272600f09 100644 --- a/ts-route-service/Dockerfile +++ b/ts-route-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-route-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-route-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-route-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-route-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 11178 \ No newline at end of file diff --git a/ts-seat-service/Dockerfile b/ts-seat-service/Dockerfile index 83a2f32c4..9b675a079 100644 --- a/ts-seat-service/Dockerfile +++ b/ts-seat-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-seat-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-seat-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-seat-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-seat-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18898 \ No newline at end of file diff --git a/ts-security-service/Dockerfile b/ts-security-service/Dockerfile index 6825d1c1a..ebac5bb96 100644 --- a/ts-security-service/Dockerfile +++ b/ts-security-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-security-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-security-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-security-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-security-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 11188 \ No newline at end of file diff --git a/ts-station-food-service/Dockerfile b/ts-station-food-service/Dockerfile index 4c9b78c30..345184548 100644 --- a/ts-station-food-service/Dockerfile +++ b/ts-station-food-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-station-food-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-station-food-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-station-food-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-station-food-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 18855 diff --git a/ts-station-service/Dockerfile b/ts-station-service/Dockerfile index 00aa14789..49f234213 100644 --- a/ts-station-service/Dockerfile +++ b/ts-station-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-station-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-station-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-station-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-station-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12345 \ No newline at end of file diff --git a/ts-ticket-office-service/Dockerfile b/ts-ticket-office-service/Dockerfile index a74edb551..3192a9c20 100644 --- a/ts-ticket-office-service/Dockerfile +++ b/ts-ticket-office-service/Dockerfile @@ -5,13 +5,13 @@ RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shang RUN mkdir -p /app WORKDIR /app -ADD ./node_modules /app/node_modules -ADD ./package.json /app/ -ADD ./public /app/public +ADD ./ts-ticket-office-service/node_modules /app/node_modules +ADD ./ts-ticket-office-service/package.json /app/ +ADD ./ts-ticket-office-service/public /app/public # RUN npm install -ADD ./bin /app/bin -ADD ./app.js /app/ +ADD ./ts-ticket-office-service/bin /app/bin +ADD ./ts-ticket-office-service/app.js /app/ CMD [ "npm", "start" ] EXPOSE 16108 \ No newline at end of file diff --git a/ts-train-food-service/Dockerfile b/ts-train-food-service/Dockerfile index 5ee2c998d..fbbe0110d 100644 --- a/ts-train-food-service/Dockerfile +++ b/ts-train-food-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-train-food-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-train-food-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-train-food-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-train-food-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 19999 diff --git a/ts-train-service/Dockerfile b/ts-train-service/Dockerfile index dca976b9c..4b031c366 100644 --- a/ts-train-service/Dockerfile +++ b/ts-train-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-train-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-train-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-train-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-train-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 14567 \ No newline at end of file diff --git a/ts-travel-plan-service/Dockerfile b/ts-travel-plan-service/Dockerfile index ae28dff03..60dfc1cea 100644 --- a/ts-travel-plan-service/Dockerfile +++ b/ts-travel-plan-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-travel-plan-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-travel-plan-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-travel-plan-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-travel-plan-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 14322 \ No newline at end of file diff --git a/ts-travel-service/Dockerfile b/ts-travel-service/Dockerfile index b5157fc04..9ee073af7 100644 --- a/ts-travel-service/Dockerfile +++ b/ts-travel-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-travel-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-travel-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-travel-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-travel-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12346 \ No newline at end of file diff --git a/ts-travel2-service/Dockerfile b/ts-travel2-service/Dockerfile index bce03eeda..2ce020f4d 100644 --- a/ts-travel2-service/Dockerfile +++ b/ts-travel2-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-travel2-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-travel2-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-travel2-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-travel2-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 16346 \ No newline at end of file diff --git a/ts-ui-dashboard/Dockerfile b/ts-ui-dashboard/Dockerfile index c974d15b5..ec63c8f32 100644 --- a/ts-ui-dashboard/Dockerfile +++ b/ts-ui-dashboard/Dockerfile @@ -2,6 +2,6 @@ FROM openresty/openresty:trusty RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -COPY nginx.conf /usr/local/openresty/nginx/conf/nginx.conf +COPY ts-ui-dashboard/nginx.conf /usr/local/openresty/nginx/conf/nginx.conf -COPY static /usr/share/nginx/html \ No newline at end of file +COPY ts-ui-dashboard/static /usr/share/nginx/html diff --git a/ts-user-service/Dockerfile b/ts-user-service/Dockerfile index de796efc9..02f71ecd5 100644 --- a/ts-user-service/Dockerfile +++ b/ts-user-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-user-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-user-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-user-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-user-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 12346 \ No newline at end of file diff --git a/ts-verification-code-service/Dockerfile b/ts-verification-code-service/Dockerfile index ae0c44bb4..6940f36ac 100644 --- a/ts-verification-code-service/Dockerfile +++ b/ts-verification-code-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-verification-code-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-verification-code-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-verification-code-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-verification-code-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 15678 \ No newline at end of file diff --git a/ts-voucher-service/Dockerfile b/ts-voucher-service/Dockerfile index f5f370097..63a9cbf70 100644 --- a/ts-voucher-service/Dockerfile +++ b/ts-voucher-service/Dockerfile @@ -5,11 +5,11 @@ RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shang RUN mkdir -p /app WORKDIR /app -COPY requirements.txt ./ +COPY ts-voucher-service/requirements.txt ./ RUN pip install cryptography RUN pip install --no-cache-dir -r requirements.txt -ADD ./server.py /app/ +ADD ./ts-voucher-service/server.py /app/ CMD [ "python", "server.py" ] EXPOSE 16101 \ No newline at end of file diff --git a/ts-wait-order-service/Dockerfile b/ts-wait-order-service/Dockerfile index 0791a9c5a..99769e4b0 100644 --- a/ts-wait-order-service/Dockerfile +++ b/ts-wait-order-service/Dockerfile @@ -1,8 +1,29 @@ +From maven:3.9.1-eclipse-temurin-8 as build +ARG SERVICE_NAME=ts-wait-order-service + +WORKDIR /app + +COPY pom.xml pom.xml +COPY ts-common/pom.xml ts-common/pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + +# Remove all modules except ts-common and $SERVICE_NAME +RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml + +RUN mvn dependency:go-offline -B + +COPY ts-common/src ./ts-common/src +COPY $SERVICE_NAME/src ./$SERVICE_NAME/src + +RUN mvn package -DskipTests + FROM eclipse-temurin:8-jre +ARG SERVICE_NAME=ts-wait-order-service +ENV SERVICE_NAME=$SERVICE_NAME RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone -ADD ./target/ts-wait-order-service-1.0.jar /app/ -CMD ["java", "-Xmx200m", "-jar", "/app/ts-wait-order-service-1.0.jar"] +COPY --from=build /app/$SERVICE_NAME/target/$SERVICE_NAME-1.0.jar /app/ +CMD java -Xmx200m -jar /app/$SERVICE_NAME-1.0.jar EXPOSE 15678 \ No newline at end of file From 41ccde1b67137df4eee5403d9a55001035db0bce Mon Sep 17 00:00:00 2001 From: jyeros Date: Sun, 14 May 2023 23:26:54 -0500 Subject: [PATCH 08/13] Ignore built kubernetes files --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index 698696d4b..b7ac882f4 100644 --- a/.gitignore +++ b/.gitignore @@ -33,3 +33,5 @@ ENV/ env.bak/ venv.bak/ +deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml +deployment/kubernetes-manifests/quickstart-k8s/yamls/secret.yaml From dbdee2a97edbe7b4a0fdb077c44f777357f1d824 Mon Sep 17 00:00:00 2001 From: jyeros Date: Sun, 14 May 2023 23:28:46 -0500 Subject: [PATCH 09/13] Speed up build, create common base for cache --- ts-admin-basic-info-service/Dockerfile | 13 +++++++------ ts-admin-order-service/Dockerfile | 13 +++++++------ ts-admin-route-service/Dockerfile | 13 +++++++------ ts-admin-travel-service/Dockerfile | 13 +++++++------ ts-admin-user-service/Dockerfile | 13 +++++++------ ts-assurance-service/Dockerfile | 13 +++++++------ ts-auth-service/Dockerfile | 13 +++++++------ ts-basic-service/Dockerfile | 13 +++++++------ ts-cancel-service/Dockerfile | 13 +++++++------ ts-config-service/Dockerfile | 13 +++++++------ ts-consign-price-service/Dockerfile | 13 +++++++------ ts-consign-service/Dockerfile | 13 +++++++------ ts-contacts-service/Dockerfile | 13 +++++++------ ts-delivery-service/Dockerfile | 13 +++++++------ ts-execute-service/Dockerfile | 13 +++++++------ ts-food-delivery-service/Dockerfile | 13 +++++++------ ts-food-service/Dockerfile | 13 +++++++------ ts-gateway-service/Dockerfile | 13 +++++++------ ts-inside-payment-service/Dockerfile | 13 +++++++------ ts-notification-service/Dockerfile | 13 +++++++------ ts-order-other-service/Dockerfile | 13 +++++++------ ts-order-service/Dockerfile | 13 +++++++------ ts-payment-service/Dockerfile | 13 +++++++------ ts-preserve-other-service/Dockerfile | 13 +++++++------ ts-preserve-service/Dockerfile | 13 +++++++------ ts-price-service/Dockerfile | 13 +++++++------ ts-rebook-service/Dockerfile | 13 +++++++------ ts-route-plan-service/Dockerfile | 13 +++++++------ ts-route-service/Dockerfile | 13 +++++++------ ts-seat-service/Dockerfile | 13 +++++++------ ts-security-service/Dockerfile | 13 +++++++------ ts-station-food-service/Dockerfile | 13 +++++++------ ts-station-service/Dockerfile | 13 +++++++------ ts-train-food-service/Dockerfile | 13 +++++++------ ts-train-service/Dockerfile | 13 +++++++------ ts-travel-plan-service/Dockerfile | 13 +++++++------ ts-travel-service/Dockerfile | 13 +++++++------ ts-travel2-service/Dockerfile | 13 +++++++------ ts-user-service/Dockerfile | 13 +++++++------ ts-verification-code-service/Dockerfile | 13 +++++++------ ts-wait-order-service/Dockerfile | 13 +++++++------ 41 files changed, 287 insertions(+), 246 deletions(-) diff --git a/ts-admin-basic-info-service/Dockerfile b/ts-admin-basic-info-service/Dockerfile index 8dade4bcf..f6b1b7907 100644 --- a/ts-admin-basic-info-service/Dockerfile +++ b/ts-admin-basic-info-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-admin-basic-info-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-admin-basic-info-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-admin-order-service/Dockerfile b/ts-admin-order-service/Dockerfile index d7bec2350..613b390cd 100644 --- a/ts-admin-order-service/Dockerfile +++ b/ts-admin-order-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-admin-order-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-admin-order-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-admin-route-service/Dockerfile b/ts-admin-route-service/Dockerfile index 78c039258..1acc197f5 100644 --- a/ts-admin-route-service/Dockerfile +++ b/ts-admin-route-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-admin-route-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-admin-route-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-admin-travel-service/Dockerfile b/ts-admin-travel-service/Dockerfile index e69c254c5..953599762 100644 --- a/ts-admin-travel-service/Dockerfile +++ b/ts-admin-travel-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-admin-travel-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-admin-travel-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-admin-user-service/Dockerfile b/ts-admin-user-service/Dockerfile index de344fcd8..6309f7c48 100644 --- a/ts-admin-user-service/Dockerfile +++ b/ts-admin-user-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-admin-user-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-admin-user-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-assurance-service/Dockerfile b/ts-assurance-service/Dockerfile index f3885d238..1dfc70a37 100644 --- a/ts-assurance-service/Dockerfile +++ b/ts-assurance-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-assurance-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-assurance-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-auth-service/Dockerfile b/ts-auth-service/Dockerfile index 9732b8c03..1ca42b81a 100644 --- a/ts-auth-service/Dockerfile +++ b/ts-auth-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-auth-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-auth-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-basic-service/Dockerfile b/ts-basic-service/Dockerfile index 8e1c53cb1..6375c8fee 100644 --- a/ts-basic-service/Dockerfile +++ b/ts-basic-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-basic-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-basic-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-cancel-service/Dockerfile b/ts-cancel-service/Dockerfile index fcf140f21..1dac5d90c 100644 --- a/ts-cancel-service/Dockerfile +++ b/ts-cancel-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-cancel-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-cancel-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-config-service/Dockerfile b/ts-config-service/Dockerfile index 3f32942ff..c03020bd5 100644 --- a/ts-config-service/Dockerfile +++ b/ts-config-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-config-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-config-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-consign-price-service/Dockerfile b/ts-consign-price-service/Dockerfile index 00beccb27..57e71c927 100644 --- a/ts-consign-price-service/Dockerfile +++ b/ts-consign-price-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-consign-price-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-consign-price-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-consign-service/Dockerfile b/ts-consign-service/Dockerfile index 3f63611ea..1a1e033ba 100644 --- a/ts-consign-service/Dockerfile +++ b/ts-consign-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-consign-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-consign-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-contacts-service/Dockerfile b/ts-contacts-service/Dockerfile index 9132f5b49..2f2bb6271 100644 --- a/ts-contacts-service/Dockerfile +++ b/ts-contacts-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-contacts-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-contacts-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-delivery-service/Dockerfile b/ts-delivery-service/Dockerfile index 7f3d7e331..337ece9a8 100644 --- a/ts-delivery-service/Dockerfile +++ b/ts-delivery-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-delivery-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-delivery-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-execute-service/Dockerfile b/ts-execute-service/Dockerfile index 788a0e1b9..83b9e5920 100644 --- a/ts-execute-service/Dockerfile +++ b/ts-execute-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-execute-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-execute-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-food-delivery-service/Dockerfile b/ts-food-delivery-service/Dockerfile index c68f5a7de..91043533f 100644 --- a/ts-food-delivery-service/Dockerfile +++ b/ts-food-delivery-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-food-delivery-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-food-delivery-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-food-service/Dockerfile b/ts-food-service/Dockerfile index bcf06b215..cd7b50b54 100644 --- a/ts-food-service/Dockerfile +++ b/ts-food-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-food-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-food-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-gateway-service/Dockerfile b/ts-gateway-service/Dockerfile index 66a308389..cdd21745a 100644 --- a/ts-gateway-service/Dockerfile +++ b/ts-gateway-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-gateway-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-gateway-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-inside-payment-service/Dockerfile b/ts-inside-payment-service/Dockerfile index 2bc0998b4..2f1cd51d3 100644 --- a/ts-inside-payment-service/Dockerfile +++ b/ts-inside-payment-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-inside-payment-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-inside-payment-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-notification-service/Dockerfile b/ts-notification-service/Dockerfile index 4cceee0c9..404ef67bb 100644 --- a/ts-notification-service/Dockerfile +++ b/ts-notification-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-notification-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-notification-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-order-other-service/Dockerfile b/ts-order-other-service/Dockerfile index 866385845..d7b157e4c 100644 --- a/ts-order-other-service/Dockerfile +++ b/ts-order-other-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-order-other-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-order-other-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-order-service/Dockerfile b/ts-order-service/Dockerfile index 24567d90a..30288db28 100644 --- a/ts-order-service/Dockerfile +++ b/ts-order-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-order-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-order-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-payment-service/Dockerfile b/ts-payment-service/Dockerfile index 84d1eef38..aa66f5e37 100644 --- a/ts-payment-service/Dockerfile +++ b/ts-payment-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-payment-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-payment-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-preserve-other-service/Dockerfile b/ts-preserve-other-service/Dockerfile index fdd5de637..ca9822a5d 100644 --- a/ts-preserve-other-service/Dockerfile +++ b/ts-preserve-other-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-preserve-other-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-preserve-other-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-preserve-service/Dockerfile b/ts-preserve-service/Dockerfile index b34cb8278..89f72f67c 100644 --- a/ts-preserve-service/Dockerfile +++ b/ts-preserve-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-preserve-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-preserve-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-price-service/Dockerfile b/ts-price-service/Dockerfile index e20f266a0..a7ea61521 100644 --- a/ts-price-service/Dockerfile +++ b/ts-price-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-price-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-price-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-rebook-service/Dockerfile b/ts-rebook-service/Dockerfile index 4b935dc58..128307a51 100644 --- a/ts-rebook-service/Dockerfile +++ b/ts-rebook-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-rebook-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-rebook-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-route-plan-service/Dockerfile b/ts-route-plan-service/Dockerfile index c3c0c0e82..71b022f4c 100644 --- a/ts-route-plan-service/Dockerfile +++ b/ts-route-plan-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-route-plan-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-route-plan-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-route-service/Dockerfile b/ts-route-service/Dockerfile index 272600f09..b317d0eb7 100644 --- a/ts-route-service/Dockerfile +++ b/ts-route-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-route-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-route-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-seat-service/Dockerfile b/ts-seat-service/Dockerfile index 9b675a079..15543176b 100644 --- a/ts-seat-service/Dockerfile +++ b/ts-seat-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-seat-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-seat-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-security-service/Dockerfile b/ts-security-service/Dockerfile index ebac5bb96..eb155b457 100644 --- a/ts-security-service/Dockerfile +++ b/ts-security-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-security-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-security-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-station-food-service/Dockerfile b/ts-station-food-service/Dockerfile index 345184548..6b9ddc742 100644 --- a/ts-station-food-service/Dockerfile +++ b/ts-station-food-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-station-food-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-station-food-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-station-service/Dockerfile b/ts-station-service/Dockerfile index 49f234213..c854193b0 100644 --- a/ts-station-service/Dockerfile +++ b/ts-station-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-station-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-station-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-train-food-service/Dockerfile b/ts-train-food-service/Dockerfile index fbbe0110d..2927a8f1e 100644 --- a/ts-train-food-service/Dockerfile +++ b/ts-train-food-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-train-food-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-train-food-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-train-service/Dockerfile b/ts-train-service/Dockerfile index 4b031c366..9167e6374 100644 --- a/ts-train-service/Dockerfile +++ b/ts-train-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-train-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-train-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-travel-plan-service/Dockerfile b/ts-travel-plan-service/Dockerfile index 60dfc1cea..57a0d1616 100644 --- a/ts-travel-plan-service/Dockerfile +++ b/ts-travel-plan-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-travel-plan-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-travel-plan-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-travel-service/Dockerfile b/ts-travel-service/Dockerfile index 9ee073af7..aea84c5cd 100644 --- a/ts-travel-service/Dockerfile +++ b/ts-travel-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-travel-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-travel-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-travel2-service/Dockerfile b/ts-travel2-service/Dockerfile index 2ce020f4d..6701ab5e5 100644 --- a/ts-travel2-service/Dockerfile +++ b/ts-travel2-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-travel2-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-travel2-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-user-service/Dockerfile b/ts-user-service/Dockerfile index 02f71ecd5..8321e1c45 100644 --- a/ts-user-service/Dockerfile +++ b/ts-user-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-user-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-user-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-verification-code-service/Dockerfile b/ts-verification-code-service/Dockerfile index 6940f36ac..d74e1ecdb 100644 --- a/ts-verification-code-service/Dockerfile +++ b/ts-verification-code-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-verification-code-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-verification-code-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src diff --git a/ts-wait-order-service/Dockerfile b/ts-wait-order-service/Dockerfile index 99769e4b0..5f24868fe 100644 --- a/ts-wait-order-service/Dockerfile +++ b/ts-wait-order-service/Dockerfile @@ -1,17 +1,18 @@ From maven:3.9.1-eclipse-temurin-8 as build -ARG SERVICE_NAME=ts-wait-order-service WORKDIR /app COPY pom.xml pom.xml COPY ts-common/pom.xml ts-common/pom.xml -COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml - -# Remove all modules except ts-common and $SERVICE_NAME -RUN sed -i "/\(ts-common\|$SERVICE_NAME\)<\/module>/!{/.*<\/module>/d}" pom.xml - +# Remove all modules except ts-common +RUN sed -i "/\(ts-common\)<\/module>/!{/.*<\/module>/d}" pom.xml RUN mvn dependency:go-offline -B +ARG SERVICE_NAME=ts-wait-order-service +# Add $SERVICE_NAME module +RUN sed -i "/ts-common<\/module>/a $SERVICE_NAME" pom.xml +COPY $SERVICE_NAME/pom.xml $SERVICE_NAME/pom.xml + COPY ts-common/src ./ts-common/src COPY $SERVICE_NAME/src ./$SERVICE_NAME/src From d7b2d06da2acdfddc6f83f02beb10e6cce5f733b Mon Sep 17 00:00:00 2001 From: jyeros Date: Tue, 16 May 2023 00:53:07 -0500 Subject: [PATCH 10/13] Add dockerignore files --- ts-admin-basic-info-service/Dockerfile.dockerignore | 6 ++++++ ts-admin-order-service/Dockerfile.dockerignore | 6 ++++++ ts-admin-route-service/Dockerfile.dockerignore | 6 ++++++ ts-admin-travel-service/Dockerfile.dockerignore | 6 ++++++ ts-admin-user-service/Dockerfile.dockerignore | 6 ++++++ ts-assurance-service/Dockerfile.dockerignore | 6 ++++++ ts-auth-service/Dockerfile.dockerignore | 6 ++++++ ts-basic-service/Dockerfile.dockerignore | 6 ++++++ ts-cancel-service/Dockerfile.dockerignore | 6 ++++++ ts-config-service/Dockerfile.dockerignore | 6 ++++++ ts-consign-price-service/Dockerfile.dockerignore | 6 ++++++ ts-consign-service/Dockerfile.dockerignore | 6 ++++++ ts-contacts-service/Dockerfile.dockerignore | 6 ++++++ ts-delivery-service/Dockerfile.dockerignore | 6 ++++++ ts-execute-service/Dockerfile.dockerignore | 6 ++++++ ts-food-delivery-service/Dockerfile.dockerignore | 6 ++++++ ts-food-service/Dockerfile.dockerignore | 6 ++++++ ts-gateway-service/Dockerfile.dockerignore | 6 ++++++ ts-inside-payment-service/Dockerfile.dockerignore | 6 ++++++ ts-notification-service/Dockerfile.dockerignore | 6 ++++++ ts-order-other-service/Dockerfile.dockerignore | 6 ++++++ ts-order-service/Dockerfile.dockerignore | 6 ++++++ ts-payment-service/Dockerfile.dockerignore | 6 ++++++ ts-preserve-other-service/Dockerfile.dockerignore | 6 ++++++ ts-preserve-service/Dockerfile.dockerignore | 6 ++++++ ts-price-service/Dockerfile.dockerignore | 6 ++++++ ts-rebook-service/Dockerfile.dockerignore | 6 ++++++ ts-route-plan-service/Dockerfile.dockerignore | 6 ++++++ ts-route-service/Dockerfile.dockerignore | 6 ++++++ ts-seat-service/Dockerfile.dockerignore | 6 ++++++ ts-security-service/Dockerfile.dockerignore | 6 ++++++ ts-station-food-service/Dockerfile.dockerignore | 6 ++++++ ts-station-service/Dockerfile.dockerignore | 6 ++++++ ts-train-food-service/Dockerfile.dockerignore | 6 ++++++ ts-train-service/Dockerfile.dockerignore | 6 ++++++ ts-travel-plan-service/Dockerfile.dockerignore | 6 ++++++ ts-travel-service/Dockerfile.dockerignore | 6 ++++++ ts-travel2-service/Dockerfile.dockerignore | 6 ++++++ ts-user-service/Dockerfile.dockerignore | 6 ++++++ ts-verification-code-service/Dockerfile.dockerignore | 6 ++++++ ts-wait-order-service/Dockerfile.dockerignore | 6 ++++++ 41 files changed, 246 insertions(+) create mode 100644 ts-admin-basic-info-service/Dockerfile.dockerignore create mode 100644 ts-admin-order-service/Dockerfile.dockerignore create mode 100644 ts-admin-route-service/Dockerfile.dockerignore create mode 100644 ts-admin-travel-service/Dockerfile.dockerignore create mode 100644 ts-admin-user-service/Dockerfile.dockerignore create mode 100644 ts-assurance-service/Dockerfile.dockerignore create mode 100644 ts-auth-service/Dockerfile.dockerignore create mode 100644 ts-basic-service/Dockerfile.dockerignore create mode 100644 ts-cancel-service/Dockerfile.dockerignore create mode 100644 ts-config-service/Dockerfile.dockerignore create mode 100644 ts-consign-price-service/Dockerfile.dockerignore create mode 100644 ts-consign-service/Dockerfile.dockerignore create mode 100644 ts-contacts-service/Dockerfile.dockerignore create mode 100644 ts-delivery-service/Dockerfile.dockerignore create mode 100644 ts-execute-service/Dockerfile.dockerignore create mode 100644 ts-food-delivery-service/Dockerfile.dockerignore create mode 100644 ts-food-service/Dockerfile.dockerignore create mode 100644 ts-gateway-service/Dockerfile.dockerignore create mode 100644 ts-inside-payment-service/Dockerfile.dockerignore create mode 100644 ts-notification-service/Dockerfile.dockerignore create mode 100644 ts-order-other-service/Dockerfile.dockerignore create mode 100644 ts-order-service/Dockerfile.dockerignore create mode 100644 ts-payment-service/Dockerfile.dockerignore create mode 100644 ts-preserve-other-service/Dockerfile.dockerignore create mode 100644 ts-preserve-service/Dockerfile.dockerignore create mode 100644 ts-price-service/Dockerfile.dockerignore create mode 100644 ts-rebook-service/Dockerfile.dockerignore create mode 100644 ts-route-plan-service/Dockerfile.dockerignore create mode 100644 ts-route-service/Dockerfile.dockerignore create mode 100644 ts-seat-service/Dockerfile.dockerignore create mode 100644 ts-security-service/Dockerfile.dockerignore create mode 100644 ts-station-food-service/Dockerfile.dockerignore create mode 100644 ts-station-service/Dockerfile.dockerignore create mode 100644 ts-train-food-service/Dockerfile.dockerignore create mode 100644 ts-train-service/Dockerfile.dockerignore create mode 100644 ts-travel-plan-service/Dockerfile.dockerignore create mode 100644 ts-travel-service/Dockerfile.dockerignore create mode 100644 ts-travel2-service/Dockerfile.dockerignore create mode 100644 ts-user-service/Dockerfile.dockerignore create mode 100644 ts-verification-code-service/Dockerfile.dockerignore create mode 100644 ts-wait-order-service/Dockerfile.dockerignore diff --git a/ts-admin-basic-info-service/Dockerfile.dockerignore b/ts-admin-basic-info-service/Dockerfile.dockerignore new file mode 100644 index 000000000..5c86a6bab --- /dev/null +++ b/ts-admin-basic-info-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-admin-basic-info-service/pom.xml +!/ts-admin-basic-info-service/src diff --git a/ts-admin-order-service/Dockerfile.dockerignore b/ts-admin-order-service/Dockerfile.dockerignore new file mode 100644 index 000000000..eae07b622 --- /dev/null +++ b/ts-admin-order-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-admin-order-service/pom.xml +!/ts-admin-order-service/src diff --git a/ts-admin-route-service/Dockerfile.dockerignore b/ts-admin-route-service/Dockerfile.dockerignore new file mode 100644 index 000000000..44de217cd --- /dev/null +++ b/ts-admin-route-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-admin-route-service/pom.xml +!/ts-admin-route-service/src diff --git a/ts-admin-travel-service/Dockerfile.dockerignore b/ts-admin-travel-service/Dockerfile.dockerignore new file mode 100644 index 000000000..b9a431705 --- /dev/null +++ b/ts-admin-travel-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-admin-travel-service/pom.xml +!/ts-admin-travel-service/src diff --git a/ts-admin-user-service/Dockerfile.dockerignore b/ts-admin-user-service/Dockerfile.dockerignore new file mode 100644 index 000000000..59de3eae9 --- /dev/null +++ b/ts-admin-user-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-admin-user-service/pom.xml +!/ts-admin-user-service/src diff --git a/ts-assurance-service/Dockerfile.dockerignore b/ts-assurance-service/Dockerfile.dockerignore new file mode 100644 index 000000000..a6f6af5cf --- /dev/null +++ b/ts-assurance-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-assurance-service/pom.xml +!/ts-assurance-service/src diff --git a/ts-auth-service/Dockerfile.dockerignore b/ts-auth-service/Dockerfile.dockerignore new file mode 100644 index 000000000..136945d3a --- /dev/null +++ b/ts-auth-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-auth-service/pom.xml +!/ts-auth-service/src diff --git a/ts-basic-service/Dockerfile.dockerignore b/ts-basic-service/Dockerfile.dockerignore new file mode 100644 index 000000000..22301f105 --- /dev/null +++ b/ts-basic-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-basic-service/pom.xml +!/ts-basic-service/src diff --git a/ts-cancel-service/Dockerfile.dockerignore b/ts-cancel-service/Dockerfile.dockerignore new file mode 100644 index 000000000..08eb06f1f --- /dev/null +++ b/ts-cancel-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-cancel-service/pom.xml +!/ts-cancel-service/src diff --git a/ts-config-service/Dockerfile.dockerignore b/ts-config-service/Dockerfile.dockerignore new file mode 100644 index 000000000..00fff6de5 --- /dev/null +++ b/ts-config-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-config-service/pom.xml +!/ts-config-service/src diff --git a/ts-consign-price-service/Dockerfile.dockerignore b/ts-consign-price-service/Dockerfile.dockerignore new file mode 100644 index 000000000..cd98ad02c --- /dev/null +++ b/ts-consign-price-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-consign-price-service/pom.xml +!/ts-consign-price-service/src diff --git a/ts-consign-service/Dockerfile.dockerignore b/ts-consign-service/Dockerfile.dockerignore new file mode 100644 index 000000000..61006d7a8 --- /dev/null +++ b/ts-consign-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-consign-service/pom.xml +!/ts-consign-service/src diff --git a/ts-contacts-service/Dockerfile.dockerignore b/ts-contacts-service/Dockerfile.dockerignore new file mode 100644 index 000000000..371fdae4f --- /dev/null +++ b/ts-contacts-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-contacts-service/pom.xml +!/ts-contacts-service/src diff --git a/ts-delivery-service/Dockerfile.dockerignore b/ts-delivery-service/Dockerfile.dockerignore new file mode 100644 index 000000000..97edd9587 --- /dev/null +++ b/ts-delivery-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-delivery-service/pom.xml +!/ts-delivery-service/src diff --git a/ts-execute-service/Dockerfile.dockerignore b/ts-execute-service/Dockerfile.dockerignore new file mode 100644 index 000000000..487355c14 --- /dev/null +++ b/ts-execute-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-execute-service/pom.xml +!/ts-execute-service/src diff --git a/ts-food-delivery-service/Dockerfile.dockerignore b/ts-food-delivery-service/Dockerfile.dockerignore new file mode 100644 index 000000000..0adb24651 --- /dev/null +++ b/ts-food-delivery-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-food-delivery-service/pom.xml +!/ts-food-delivery-service/src diff --git a/ts-food-service/Dockerfile.dockerignore b/ts-food-service/Dockerfile.dockerignore new file mode 100644 index 000000000..977b0d27f --- /dev/null +++ b/ts-food-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-food-service/pom.xml +!/ts-food-service/src diff --git a/ts-gateway-service/Dockerfile.dockerignore b/ts-gateway-service/Dockerfile.dockerignore new file mode 100644 index 000000000..db7c12379 --- /dev/null +++ b/ts-gateway-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-gateway-service/pom.xml +!/ts-gateway-service/src diff --git a/ts-inside-payment-service/Dockerfile.dockerignore b/ts-inside-payment-service/Dockerfile.dockerignore new file mode 100644 index 000000000..ba3dbc90a --- /dev/null +++ b/ts-inside-payment-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-inside-payment-service/pom.xml +!/ts-inside-payment-service/src diff --git a/ts-notification-service/Dockerfile.dockerignore b/ts-notification-service/Dockerfile.dockerignore new file mode 100644 index 000000000..85820f0a5 --- /dev/null +++ b/ts-notification-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-notification-service/pom.xml +!/ts-notification-service/src diff --git a/ts-order-other-service/Dockerfile.dockerignore b/ts-order-other-service/Dockerfile.dockerignore new file mode 100644 index 000000000..bc701dc82 --- /dev/null +++ b/ts-order-other-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-order-other-service/pom.xml +!/ts-order-other-service/src diff --git a/ts-order-service/Dockerfile.dockerignore b/ts-order-service/Dockerfile.dockerignore new file mode 100644 index 000000000..bcb4b06e6 --- /dev/null +++ b/ts-order-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-order-service/pom.xml +!/ts-order-service/src diff --git a/ts-payment-service/Dockerfile.dockerignore b/ts-payment-service/Dockerfile.dockerignore new file mode 100644 index 000000000..c578e7ac6 --- /dev/null +++ b/ts-payment-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-payment-service/pom.xml +!/ts-payment-service/src diff --git a/ts-preserve-other-service/Dockerfile.dockerignore b/ts-preserve-other-service/Dockerfile.dockerignore new file mode 100644 index 000000000..d9679a3e2 --- /dev/null +++ b/ts-preserve-other-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-preserve-other-service/pom.xml +!/ts-preserve-other-service/src diff --git a/ts-preserve-service/Dockerfile.dockerignore b/ts-preserve-service/Dockerfile.dockerignore new file mode 100644 index 000000000..d98e7fd6d --- /dev/null +++ b/ts-preserve-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-preserve-service/pom.xml +!/ts-preserve-service/src diff --git a/ts-price-service/Dockerfile.dockerignore b/ts-price-service/Dockerfile.dockerignore new file mode 100644 index 000000000..79be30c2c --- /dev/null +++ b/ts-price-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-price-service/pom.xml +!/ts-price-service/src diff --git a/ts-rebook-service/Dockerfile.dockerignore b/ts-rebook-service/Dockerfile.dockerignore new file mode 100644 index 000000000..335531d2d --- /dev/null +++ b/ts-rebook-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-rebook-service/pom.xml +!/ts-rebook-service/src diff --git a/ts-route-plan-service/Dockerfile.dockerignore b/ts-route-plan-service/Dockerfile.dockerignore new file mode 100644 index 000000000..a3c0fd331 --- /dev/null +++ b/ts-route-plan-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-route-plan-service/pom.xml +!/ts-route-plan-service/src diff --git a/ts-route-service/Dockerfile.dockerignore b/ts-route-service/Dockerfile.dockerignore new file mode 100644 index 000000000..f039ac050 --- /dev/null +++ b/ts-route-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-route-service/pom.xml +!/ts-route-service/src diff --git a/ts-seat-service/Dockerfile.dockerignore b/ts-seat-service/Dockerfile.dockerignore new file mode 100644 index 000000000..d1d14b326 --- /dev/null +++ b/ts-seat-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-seat-service/pom.xml +!/ts-seat-service/src diff --git a/ts-security-service/Dockerfile.dockerignore b/ts-security-service/Dockerfile.dockerignore new file mode 100644 index 000000000..26bd24224 --- /dev/null +++ b/ts-security-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-security-service/pom.xml +!/ts-security-service/src diff --git a/ts-station-food-service/Dockerfile.dockerignore b/ts-station-food-service/Dockerfile.dockerignore new file mode 100644 index 000000000..712b0ecfb --- /dev/null +++ b/ts-station-food-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-station-food-service/pom.xml +!/ts-station-food-service/src diff --git a/ts-station-service/Dockerfile.dockerignore b/ts-station-service/Dockerfile.dockerignore new file mode 100644 index 000000000..bcad812cd --- /dev/null +++ b/ts-station-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-station-service/pom.xml +!/ts-station-service/src diff --git a/ts-train-food-service/Dockerfile.dockerignore b/ts-train-food-service/Dockerfile.dockerignore new file mode 100644 index 000000000..bc7073f60 --- /dev/null +++ b/ts-train-food-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-train-food-service/pom.xml +!/ts-train-food-service/src diff --git a/ts-train-service/Dockerfile.dockerignore b/ts-train-service/Dockerfile.dockerignore new file mode 100644 index 000000000..1281d2e66 --- /dev/null +++ b/ts-train-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-train-service/pom.xml +!/ts-train-service/src diff --git a/ts-travel-plan-service/Dockerfile.dockerignore b/ts-travel-plan-service/Dockerfile.dockerignore new file mode 100644 index 000000000..c612967f1 --- /dev/null +++ b/ts-travel-plan-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-travel-plan-service/pom.xml +!/ts-travel-plan-service/src diff --git a/ts-travel-service/Dockerfile.dockerignore b/ts-travel-service/Dockerfile.dockerignore new file mode 100644 index 000000000..8c9d9df2a --- /dev/null +++ b/ts-travel-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-travel-service/pom.xml +!/ts-travel-service/src diff --git a/ts-travel2-service/Dockerfile.dockerignore b/ts-travel2-service/Dockerfile.dockerignore new file mode 100644 index 000000000..af0eacc10 --- /dev/null +++ b/ts-travel2-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-travel2-service/pom.xml +!/ts-travel2-service/src diff --git a/ts-user-service/Dockerfile.dockerignore b/ts-user-service/Dockerfile.dockerignore new file mode 100644 index 000000000..45980d3ec --- /dev/null +++ b/ts-user-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-user-service/pom.xml +!/ts-user-service/src diff --git a/ts-verification-code-service/Dockerfile.dockerignore b/ts-verification-code-service/Dockerfile.dockerignore new file mode 100644 index 000000000..c46cfa0f8 --- /dev/null +++ b/ts-verification-code-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-verification-code-service/pom.xml +!/ts-verification-code-service/src diff --git a/ts-wait-order-service/Dockerfile.dockerignore b/ts-wait-order-service/Dockerfile.dockerignore new file mode 100644 index 000000000..8ade5e1d9 --- /dev/null +++ b/ts-wait-order-service/Dockerfile.dockerignore @@ -0,0 +1,6 @@ +* +!/pom.xml +!/ts-common/pom.xml +!/ts-common/src +!/ts-wait-order-service/pom.xml +!/ts-wait-order-service/src From d4fe2203757a11091cf5cf33694b1825fe3ee37f Mon Sep 17 00:00:00 2001 From: jyeros Date: Tue, 16 May 2023 01:14:29 -0500 Subject: [PATCH 11/13] Ignore vscode files --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index b7ac882f4..eff4983c9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ .idea +.vscode *.dat *.original *.lst From 5097ffee3e0853e989494bef71291b4b79b11732 Mon Sep 17 00:00:00 2001 From: jyeros Date: Tue, 23 May 2023 16:00:23 -0500 Subject: [PATCH 12/13] Expose elasatic search port --- deployment/kubernetes-manifests/skywalking/es.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/deployment/kubernetes-manifests/skywalking/es.yml b/deployment/kubernetes-manifests/skywalking/es.yml index c5c458e2d..71b4625f8 100644 --- a/deployment/kubernetes-manifests/skywalking/es.yml +++ b/deployment/kubernetes-manifests/skywalking/es.yml @@ -4,11 +4,13 @@ metadata: creationTimestamp: null name: elasticsearch spec: + type: NodePort ports: - name: db port: 9200 protocol: TCP targetPort: 9200 + nodePort: 30092 - name: transport port: 9300 protocol: TCP From db1121590827244d70dfbcc3b1220f1d76333712 Mon Sep 17 00:00:00 2001 From: jyeros Date: Tue, 23 May 2023 16:00:48 -0500 Subject: [PATCH 13/13] Ignore generated files --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index eff4983c9..ebbc753d3 100644 --- a/.gitignore +++ b/.gitignore @@ -36,3 +36,4 @@ venv.bak/ deployment/kubernetes-manifests/quickstart-k8s/yamls/deploy.yaml deployment/kubernetes-manifests/quickstart-k8s/yamls/secret.yaml +deployment/kubernetes-manifests/quickstart-k8s/yamls/sw_deploy.yaml