From 66e80e0a53e628a62487d95cca2829b7293d2533 Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:15:58 +0800 Subject: [PATCH 01/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 14 ++++++++++---- requirements3.txt | 2 +- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 78d7a167..484a7298 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -28,7 +28,7 @@ jobs: - name: Set up RPM build env run: | - sudo apt-get update && sudo apt-get install -y rpm + sudo apt-get update && sudo apt-get install -y rpm alien - name: Build package run: | @@ -38,9 +38,15 @@ jobs: cat ./rpm/oceanbase-diagnostic-tool.spec rpmbuild -bb ./rpm/oceanbase-diagnostic-tool.spec - - name: 'Upload Artifact' + - name: Convert RPM to DEB + run: | + alien --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + + - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 with: - name: obdiag - path: /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + name: obdiag-packages + path: | + /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool_*.deb retention-days: 3 \ No newline at end of file diff --git a/requirements3.txt b/requirements3.txt index ef1ff40d..6ca1831e 100644 --- a/requirements3.txt +++ b/requirements3.txt @@ -20,7 +20,7 @@ zstandard==0.17.0 pycryptodome~=3.14.1 pick==1.2.0 PyYAML==6.0 -prettytable==3.5.0 +prettytable==3.10.0 oyaml==1.0 xmltodict==0.13.0 subprocess32==3.5.4 From e8eddd0b50866ad7790fd0cfc6e8349e9fd2eeb8 Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:20:50 +0800 Subject: [PATCH 02/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 484a7298..9b6fff17 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -28,7 +28,7 @@ jobs: - name: Set up RPM build env run: | - sudo apt-get update && sudo apt-get install -y rpm alien + sudo apt-get update && sudo apt-get install -y rpm alien fakeroot - name: Build package run: | @@ -40,7 +40,7 @@ jobs: - name: Convert RPM to DEB run: | - alien --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + fakeroot alien --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 From ad81358aaea432d857b89f7c99ebab6c74e93cfd Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:28:42 +0800 Subject: [PATCH 03/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 9b6fff17..7f6d3ccd 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -40,7 +40,7 @@ jobs: - name: Convert RPM to DEB run: | - fakeroot alien --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + fakeroot alien --scripts --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 @@ -49,4 +49,5 @@ jobs: path: | /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool_*.deb - retention-days: 3 \ No newline at end of file + retention-days: 3 + debug: true \ No newline at end of file From c6ee51c6ffc49dafc78433f56fbdcf911589f492 Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:34:07 +0800 Subject: [PATCH 04/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 7f6d3ccd..90d7779b 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -42,6 +42,10 @@ jobs: run: | fakeroot alien --scripts --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + - name: Find DEB package + run: | + find /home/runner/rpmbuild -name 'oceanbase-diagnostic-tool_*.deb' + - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 with: From 66af4c5f0e207f789199734e3b9f3393e83571c1 Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:39:12 +0800 Subject: [PATCH 05/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 90d7779b..c957a356 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -40,11 +40,12 @@ jobs: - name: Convert RPM to DEB run: | - fakeroot alien --scripts --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + mkdir -p /home/runner/deb + fakeroot alien --scripts --to-deb --target /home/runner/deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: Find DEB package run: | - find /home/runner/rpmbuild -name 'oceanbase-diagnostic-tool_*.deb' + find /home/runner/deb -name 'oceanbase-diagnostic-tool_*.deb' - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 @@ -52,6 +53,6 @@ jobs: name: obdiag-packages path: | /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool_*.deb + /home/runner/deb/oceanbase-diagnostic-tool_*.deb retention-days: 3 debug: true \ No newline at end of file From 26fe61bc231e15648741936875d6e8d72a361889 Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:43:15 +0800 Subject: [PATCH 06/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index c957a356..5a1d729a 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -40,12 +40,12 @@ jobs: - name: Convert RPM to DEB run: | - mkdir -p /home/runner/deb - fakeroot alien --scripts --to-deb --target /home/runner/deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + mkdir -p /home/runner/artifacts + fakeroot alien --scripts --to-deb --target /home/runner/artifacts --architecture amd64 /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: Find DEB package run: | - find /home/runner/deb -name 'oceanbase-diagnostic-tool_*.deb' + find /home/runner/artifacts -name 'oceanbase-diagnostic-tool_*.deb' - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 From f3266739fe26213acadb2cb3973cef7832b6f2ae Mon Sep 17 00:00:00 2001 From: Teingi Date: Wed, 17 Apr 2024 23:47:45 +0800 Subject: [PATCH 07/10] support Convert RPM to DEB --- .github/workflows/build_rpm.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 5a1d729a..2b7ee39c 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -3,10 +3,10 @@ name: build rpm on: pull_request: branches: - - master + - "*" push: branches: - - master + - "*" jobs: build-and-package-x86_64: @@ -41,7 +41,7 @@ jobs: - name: Convert RPM to DEB run: | mkdir -p /home/runner/artifacts - fakeroot alien --scripts --to-deb --target /home/runner/artifacts --architecture amd64 /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + fakeroot alien --scripts --to-deb --target /home/runner/artifacts /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: Find DEB package run: | From 02d842a52b93a01883598ce12a2370c472f64b80 Mon Sep 17 00:00:00 2001 From: Teingi Date: Thu, 18 Apr 2024 11:10:46 +0800 Subject: [PATCH 08/10] fix --- .github/workflows/build_rpm.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index 2b7ee39c..a3ab2009 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -53,6 +53,6 @@ jobs: name: obdiag-packages path: | /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - /home/runner/deb/oceanbase-diagnostic-tool_*.deb + /home/runner/artifacts/oceanbase-diagnostic-tool_*.deb retention-days: 3 debug: true \ No newline at end of file From af8789ba39331f46febb17166bae334d5c7d69c7 Mon Sep 17 00:00:00 2001 From: Teingi Date: Thu, 18 Apr 2024 11:16:28 +0800 Subject: [PATCH 09/10] support deb package --- .github/workflows/build_rpm.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index a3ab2009..fc7b0d41 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -41,11 +41,11 @@ jobs: - name: Convert RPM to DEB run: | mkdir -p /home/runner/artifacts - fakeroot alien --scripts --to-deb --target /home/runner/artifacts /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm + fakeroot alien --scripts --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - name: Find DEB package run: | - find /home/runner/artifacts -name 'oceanbase-diagnostic-tool_*.deb' + find /home -name 'oceanbase-diagnostic-tool_*.deb' - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 @@ -53,6 +53,6 @@ jobs: name: obdiag-packages path: | /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - /home/runner/artifacts/oceanbase-diagnostic-tool_*.deb + /home/runner/oceanbase-diagnostic-tool_*.deb retention-days: 3 debug: true \ No newline at end of file From a1e107a818caffdb729b4cd5166dc97bba61579a Mon Sep 17 00:00:00 2001 From: Teingi Date: Thu, 18 Apr 2024 11:18:52 +0800 Subject: [PATCH 10/10] support deb package --- .github/workflows/build_rpm.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/build_rpm.yml b/.github/workflows/build_rpm.yml index fc7b0d41..1cd40d45 100644 --- a/.github/workflows/build_rpm.yml +++ b/.github/workflows/build_rpm.yml @@ -43,16 +43,12 @@ jobs: mkdir -p /home/runner/artifacts fakeroot alien --scripts --to-deb /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - - name: Find DEB package - run: | - find /home -name 'oceanbase-diagnostic-tool_*.deb' - - name: 'Upload Artifacts' uses: actions/upload-artifact@v3 with: name: obdiag-packages path: | /home/runner/rpmbuild/RPMS/x86_64/oceanbase-diagnostic-tool-*.rpm - /home/runner/oceanbase-diagnostic-tool_*.deb + /home/runner/work/oceanbase-diagnostic-tool/oceanbase-diagnostic-tool/oceanbase-diagnostic-tool_*.deb retention-days: 3 debug: true \ No newline at end of file