|
55 | 55 | - name: Checkout repository
|
56 | 56 | uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
|
57 | 57 |
|
58 |
| - - name: Get tag |
59 |
| - run: | |
60 |
| - if [[ "${{ github.event.inputs.version }}" ]]; then |
61 |
| - echo "TAG=${{ github.event.inputs.version }}" >> $GITHUB_ENV |
62 |
| - elif [[ "$GITHUB_REF_TYPE" == "tag" ]]; then |
63 |
| - echo "TAG=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV |
64 |
| - else |
65 |
| - echo "TAG=main" >> $GITHUB_ENV |
66 |
| - fi |
67 |
| -
|
68 | 58 | - name: Install JDK
|
69 | 59 | uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 # v4.2.1
|
70 | 60 | with:
|
@@ -104,8 +94,35 @@ jobs:
|
104 | 94 | cache-to: type=gha,mode=max
|
105 | 95 | platforms: linux/amd64, linux/arm64
|
106 | 96 | push: true
|
107 |
| - tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ env.TAG }} |
| 97 | + tags: ${{ env.REGISTRY }}/${{ github.repository }}:${{ env.VERSION }} |
108 | 98 | build-args: |
|
109 | 99 | VERSION=${{ env.VERSION }}
|
110 | 100 | build-contexts: |
|
111 | 101 | distributions=./server/build/distributions
|
| 102 | +
|
| 103 | +
|
| 104 | + helm-chart-release: |
| 105 | + needs: publish |
| 106 | + runs-on: [ self-hosted, Linux, medium, ephemeral ] |
| 107 | + permissions: |
| 108 | + contents: write |
| 109 | + |
| 110 | + steps: |
| 111 | + - name: Harden Runner |
| 112 | + uses: step-security/harden-runner@0d381219ddf674d61a7572ddd19d7941e271515c # v2.9.0 |
| 113 | + with: |
| 114 | + egress-policy: audit |
| 115 | + |
| 116 | + - name: Checkout repository |
| 117 | + uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 |
| 118 | + |
| 119 | + - name: Install Helm |
| 120 | + uses: azure/setup-helm@fe7b79cd5ee1e45176fcad797de68ecaf3ca4814 # v4.2.0 |
| 121 | + |
| 122 | + - name: Publish helm chart |
| 123 | + uses: stefanprodan/helm-gh-pages@0ad2bb377311d61ac04ad9eb6f252fb68e207260 # v1.7.0 |
| 124 | + with: |
| 125 | + target_dir: charts |
| 126 | + token: ${{ secrets.GITHUB_TOKEN }} |
| 127 | + branch: gh-pages |
| 128 | + app_version: ${{ env.VERSION }} |
0 commit comments