|
6 | 6 | # - main
|
7 | 7 |
|
8 | 8 | jobs:
|
9 |
| - # format: |
10 |
| - # runs-on: ubuntu-22.04 |
11 |
| - # container: "datadog/docker-library:kong-plugin-ddtrace-ci" |
12 |
| - # steps: |
13 |
| - # - uses: actions/checkout@v3 |
14 |
| - # - name: "Lint" |
15 |
| - # run: stylua --check kong/ spec/ |
16 |
| - # - name: "Static analysis" |
17 |
| - # run: luacheck kong spec |
18 |
| - # |
19 |
| - # run-test: |
20 |
| - # runs-on: ubuntu-22.04 |
21 |
| - # steps: |
22 |
| - # - uses: actions/checkout@v3 |
23 |
| - # - uses: Kong/kong-pongo-action@v1 |
24 |
| - # with: |
25 |
| - # kong_version: stable |
26 |
| - # pongo_version: latest |
27 |
| - # - run: pongo run --no-datadog-agent --no-postgres --no-cassandra -- --coverage |
28 |
| - # - name: Publish code coverage summary |
29 |
| - # run: | |
30 |
| - # beg=$( grep -n "Summary" < luacov.report.out | cut -d ':' -f1 ) |
31 |
| - # tail --lines=+${beg} luacov.report.out >> $GITHUB_STEP_SUMMARY |
32 |
| - # - name: Upload coverage reports to Codecov |
33 |
| - |
34 |
| - # with: |
35 |
| - # token: ${{ secrets.CODECOV_TOKEN }} |
36 |
| - # slug: DataDog/kong-plugin-ddtrace |
37 |
| - # |
38 |
| - package: |
| 9 | + format: |
| 10 | + runs-on: ubuntu-22.04 |
| 11 | + container: "datadog/docker-library:kong-plugin-ddtrace-ci" |
| 12 | + steps: |
| 13 | + - uses: actions/checkout@v3 |
| 14 | + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2 |
| 15 | + - name: "Lint" |
| 16 | + run: stylua --check kong/ spec/ |
| 17 | + - name: "Static analysis" |
| 18 | + run: luacheck kong spec |
| 19 | + |
| 20 | + run-test: |
39 | 21 | runs-on: ubuntu-22.04
|
40 |
| - # needs: [format, run-test] |
41 | 22 | steps:
|
42 | 23 | - uses: actions/checkout@v3
|
| 24 | + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2 |
| 25 | + - uses: Kong/kong-pongo-action@v1 |
| 26 | + with: |
| 27 | + kong_version: stable |
| 28 | + pongo_version: latest |
| 29 | + - run: pongo run --no-datadog-agent --no-postgres --no-cassandra -- --coverage |
| 30 | + - name: Publish code coverage summary |
| 31 | + run: | |
| 32 | + beg=$( grep -n "Summary" < luacov.report.out | cut -d ':' -f1 ) |
| 33 | + tail --lines=+${beg} luacov.report.out >> $GITHUB_STEP_SUMMARY |
| 34 | + - name: Upload coverage reports to Codecov |
| 35 | + |
| 36 | + with: |
| 37 | + token: ${{ secrets.CODECOV_TOKEN }} |
| 38 | + slug: DataDog/kong-plugin-ddtrace |
| 39 | + |
| 40 | + package: |
| 41 | + runs-on: ubuntu-22.04 |
| 42 | + needs: [format, run-test] |
| 43 | + steps: |
| 44 | + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2 |
43 | 45 | - name: Install Python
|
44 | 46 | uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 #v5.0.5
|
45 | 47 | - uses: leafo/gh-actions-lua@8aace3457a2fcf3f3c4e9007ecc6b869ff6d74d6 #v11
|
@@ -82,38 +84,38 @@ jobs:
|
82 | 84 | KONG_PLUGINS: bundled,ddtrace
|
83 | 85 | run: kong start
|
84 | 86 |
|
85 |
| - # publish-release-candidate: |
86 |
| - # runs-on: ubuntu-22.04 |
87 |
| - # needs: package |
88 |
| - # permissions: |
89 |
| - # contents: write |
90 |
| - # steps: |
91 |
| - # - uses: actions/checkout@v3 |
92 |
| - # - name: Generate pre-release metadata |
93 |
| - # run: | |
94 |
| - # { |
95 |
| - # echo "\`Commit SHA: ${GITHUB_SHA}\`" |
96 |
| - # echo "" |
97 |
| - # echo "> [!WARNING]" |
98 |
| - # echo "> **This is a pre-release build** based on the latest development." |
99 |
| - # echo "> It may introduce breaking changes, unexpected behavior, and other issues. We recommend using it only in non-critical environments." |
100 |
| - # echo "" |
101 |
| - # echo "## Install" |
102 |
| - # echo "1. Download the rock." |
103 |
| - # echo "2. Install it using luarock: \`luarock install <ROCK>.src.rock\`" |
104 |
| - # } >> $RUNNER_TEMP/notes.md |
105 |
| - # - name: Update tip tag |
106 |
| - # run: git push origin :tip || true |
107 |
| - # - name: Download a single artifact |
108 |
| - # uses: actions/download-artifact@95815c38cf2ff2164869cbab79da8d1f422bc89e #v4.2.1 |
109 |
| - # with: |
110 |
| - # name: kong-ddtrace-artifact |
111 |
| - # - name: Create or Update Release |
112 |
| - # env: |
113 |
| - # GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
114 |
| - # run: | |
115 |
| - # gh release delete tip --yes || true |
116 |
| - # gh release create tip --title "Development (pre-release) build" \ |
117 |
| - # --prerelease \ |
118 |
| - # --notes-file "$RUNNER_TEMP/notes.md" \ |
119 |
| - # --target $GITHUB_SHA kong-plugin-ddtrace*.rock |
| 87 | + publish-release-candidate: |
| 88 | + runs-on: ubuntu-22.04 |
| 89 | + needs: package |
| 90 | + permissions: |
| 91 | + contents: write |
| 92 | + steps: |
| 93 | + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4.2.2 |
| 94 | + - name: Download a single artifact |
| 95 | + uses: actions/download-artifact@95815c38cf2ff2164869cbab79da8d1f422bc89e #v4.2.1 |
| 96 | + with: |
| 97 | + name: kong-ddtrace-artifact |
| 98 | + - name: Generate pre-release metadata |
| 99 | + run: | |
| 100 | + { |
| 101 | + echo "\`Commit SHA: ${GITHUB_SHA}\`" |
| 102 | + echo "" |
| 103 | + echo "> [!WARNING]" |
| 104 | + echo "> **This is a pre-release build** based on the latest development." |
| 105 | + echo "> It may introduce breaking changes, unexpected behavior, and other issues. We recommend using it only in non-critical environments." |
| 106 | + echo "" |
| 107 | + echo "## Install" |
| 108 | + echo "1. Download the rock." |
| 109 | + echo "2. Install it using luarock: \`luarock install <ROCK>.src.rock\`" |
| 110 | + } >> $RUNNER_TEMP/notes.md |
| 111 | + - name: Update tip tag |
| 112 | + run: git push origin :tip || true |
| 113 | + - name: Create or Update Release |
| 114 | + env: |
| 115 | + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 116 | + run: | |
| 117 | + gh release delete tip --yes || true |
| 118 | + gh release create tip --title "Development (pre-release) build" \ |
| 119 | + --prerelease \ |
| 120 | + --notes-file "$RUNNER_TEMP/notes.md" \ |
| 121 | + --target $GITHUB_SHA kong-plugin-ddtrace*.rock |
0 commit comments