From 2f2a3539583e955449c2f697cdeb177cb48cc6de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= <2270033969@qq.com> Date: Sun, 13 Oct 2024 19:14:38 +0800 Subject: [PATCH 1/3] ci(docker): auto build image --- .github/workflows/image.yml | 41 +++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/image.yml diff --git a/.github/workflows/image.yml b/.github/workflows/image.yml new file mode 100644 index 000000000..6ff967bfa --- /dev/null +++ b/.github/workflows/image.yml @@ -0,0 +1,41 @@ +# This workflow will build a Java project with Maven +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven + +name: PIG 镜像 action + +on: + push: + branches: [ jdk17-dev ] + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + java-version: [ 17 ] + steps: + - uses: actions/checkout@v4 + - name: Set up JDK ${{ matrix.java-version }} + uses: actions/setup-java@v4 + with: + java-version: ${{ matrix.java-version }} + distribution: 'zulu' + + - name: mvn clean install + run: mvn clean install -Pcloud + + - name: Login to Docker Registry + run: docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }} registry.cn-hangzhou.aliyuncs.com + + - name: Build and push Docker images + run: | + docker-compose build + registry="registry.cn-hangzhou.aliyuncs.com/pigx/" + for service in $(docker-compose config --services); do + if [ "$service" != "pig-redis" ]; then + docker tag ${service}:latest ${registry}${service}:latest + docker push ${registry}${service}:latest + else + echo "Skipping pig-redis service" + fi + done From c946806733d7c19075ee5fac967d304e4c01c3ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=86=B7=E5=86=B7?= <2270033969@qq.com> Date: Sun, 13 Oct 2024 19:27:11 +0800 Subject: [PATCH 2/3] =?UTF-8?q?ci(docker):=20fix=20docker=20compose=20?= =?UTF-8?q?=E5=91=BD=E4=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/image.yml | 4 ++-- .github/workflows/maven.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/image.yml b/.github/workflows/image.yml index 6ff967bfa..88ed2058c 100644 --- a/.github/workflows/image.yml +++ b/.github/workflows/image.yml @@ -1,7 +1,7 @@ # This workflow will build a Java project with Maven # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven -name: PIG 镜像 action +name: Docker 镜像 构建 on: push: @@ -29,7 +29,7 @@ jobs: - name: Build and push Docker images run: | - docker-compose build + docker compose build registry="registry.cn-hangzhou.aliyuncs.com/pigx/" for service in $(docker-compose config --services); do if [ "$service" != "pig-redis" ]; then diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index a68c59ad1..3df333c1f 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -1,7 +1,7 @@ # This workflow will build a Java project with Maven # For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven -name: PIG 构建action +name: maven 编译检查 on: push: From 47a7e8ed518f6a43929e37db4dbddb2ffb49eca2 Mon Sep 17 00:00:00 2001 From: "2331890842@qq.com" Date: Mon, 21 Oct 2024 09:58:10 +0800 Subject: [PATCH 3/3] =?UTF-8?q?fix(=E6=97=A5=E5=BF=97):=20logback=E7=94=9F?= =?UTF-8?q?=E6=88=90=E6=97=A5=E5=BF=97=E6=96=87=E4=BB=B6=EF=BC=8C=E5=BD=A9?= =?UTF-8?q?=E8=89=B2=E6=97=A5=E5=BF=97=E6=A0=BC=E5=BC=8F=E4=BC=9A=E5=87=BA?= =?UTF-8?q?=E7=8E=B0=E4=B9=B1=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pig-auth/src/main/resources/logback-spring.xml | 5 +++-- .../pig-common-core/src/main/resources/logback-spring.xml | 5 +++-- pig-gateway/src/main/resources/logback-spring.xml | 5 +++-- .../pig-upms-biz/src/main/resources/logback-spring.xml | 7 ++++--- .../pig-codegen/src/main/resources/logback-spring.xml | 5 +++-- .../pig-monitor/src/main/resources/logback-spring.xml | 5 +++-- .../pig-quartz/src/main/resources/logback-spring.xml | 5 +++-- 7 files changed, 22 insertions(+), 15 deletions(-) diff --git a/pig-auth/src/main/resources/logback-spring.xml b/pig-auth/src/main/resources/logback-spring.xml index b3ac61a83..78f41208c 100755 --- a/pig-auth/src/main/resources/logback-spring.xml +++ b/pig-auth/src/main/resources/logback-spring.xml @@ -21,6 +21,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -56,7 +57,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-common/pig-common-core/src/main/resources/logback-spring.xml b/pig-common/pig-common-core/src/main/resources/logback-spring.xml index d9daae947..6f224df70 100755 --- a/pig-common/pig-common-core/src/main/resources/logback-spring.xml +++ b/pig-common/pig-common-core/src/main/resources/logback-spring.xml @@ -21,6 +21,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -56,7 +57,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-gateway/src/main/resources/logback-spring.xml b/pig-gateway/src/main/resources/logback-spring.xml index 460810084..fd38ce785 100755 --- a/pig-gateway/src/main/resources/logback-spring.xml +++ b/pig-gateway/src/main/resources/logback-spring.xml @@ -21,6 +21,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -56,7 +57,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-upms/pig-upms-biz/src/main/resources/logback-spring.xml b/pig-upms/pig-upms-biz/src/main/resources/logback-spring.xml index c0ce9c5b1..d0524a330 100644 --- a/pig-upms/pig-upms-biz/src/main/resources/logback-spring.xml +++ b/pig-upms/pig-upms-biz/src/main/resources/logback-spring.xml @@ -12,7 +12,8 @@ - + + @@ -34,7 +35,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -47,7 +48,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-visual/pig-codegen/src/main/resources/logback-spring.xml b/pig-visual/pig-codegen/src/main/resources/logback-spring.xml index a90ada52f..2bf56b3af 100644 --- a/pig-visual/pig-codegen/src/main/resources/logback-spring.xml +++ b/pig-visual/pig-codegen/src/main/resources/logback-spring.xml @@ -29,6 +29,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -64,7 +65,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-visual/pig-monitor/src/main/resources/logback-spring.xml b/pig-visual/pig-monitor/src/main/resources/logback-spring.xml index 460810084..fd38ce785 100755 --- a/pig-visual/pig-monitor/src/main/resources/logback-spring.xml +++ b/pig-visual/pig-monitor/src/main/resources/logback-spring.xml @@ -21,6 +21,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -56,7 +57,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR diff --git a/pig-visual/pig-quartz/src/main/resources/logback-spring.xml b/pig-visual/pig-quartz/src/main/resources/logback-spring.xml index 3ad26f7ee..13bc712da 100644 --- a/pig-visual/pig-quartz/src/main/resources/logback-spring.xml +++ b/pig-visual/pig-quartz/src/main/resources/logback-spring.xml @@ -12,6 +12,7 @@ + 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} @@ -47,7 +48,7 @@ 30 - ${CONSOLE_LOG_PATTERN} + ${FILE_LOG_PATTERN} ERROR