-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* restore helm cd action * update cd helm
- Loading branch information
Showing
1 changed file
with
65 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,65 +12,68 @@ | |
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# TODO: Enable once helm chart is updated | ||
#name: CD / Helm | ||
# | ||
#on: | ||
# push: | ||
# branches: [ master ] | ||
# | ||
#jobs: | ||
# lint-test: | ||
# name: Lint and test | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - uses: actions/[email protected] | ||
# with: | ||
# fetch-depth: 0 | ||
# - uses: azure/[email protected] | ||
# with: | ||
# version: v3.12.1 | ||
# - uses: helm/[email protected] | ||
# - id: list-changed | ||
# run: | | ||
# changed=$(ct list-changed --config=.ct.yml --target-branch ${{ github.event.repository.default_branch }}) | ||
# if [[ -n "$changed" ]]; then | ||
# echo "changed=true" >> "$GITHUB_OUTPUT" | ||
# fi | ||
# - if: steps.list-changed.outputs.changed == 'true' | ||
# run: ct lint --config=.ct.yml --target-branch ${{ github.event.repository.default_branch }} | ||
# - if: steps.list-changed.outputs.changed == 'true' | ||
# uses: helm/[email protected] | ||
# with: | ||
# node_image: kindest/node:v1.29.0 | ||
# - if: steps.list-changed.outputs.changed == 'true' | ||
# run: ct install --target-branch ${{ github.event.repository.default_branch }} | ||
# | ||
# release: | ||
# name: Helm chart release | ||
# runs-on: ubuntu-latest | ||
# needs: [ 'lint-test' ] | ||
# permissions: | ||
# contents: write | ||
# steps: | ||
# - name: Check out repository | ||
# uses: actions/[email protected] | ||
# with: | ||
# fetch-depth: 0 | ||
# | ||
# - name: Set up Git user | ||
# run: | | ||
# git config user.name "$GITHUB_ACTOR" | ||
# git config user.email "[email protected]" | ||
# | ||
# - name: Set up Helm | ||
# uses: azure/[email protected] | ||
# with: | ||
# version: v3.12.1 | ||
# | ||
# - name: Run chart-releaser | ||
# uses: helm/[email protected] | ||
# with: | ||
# skip_existing: true | ||
# env: | ||
# CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | ||
name: CD / Helm | ||
|
||
on: | ||
push: | ||
paths: | ||
- 'charts/**' | ||
branches: | ||
- master | ||
|
||
jobs: | ||
lint-test: | ||
name: Lint and test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
- uses: azure/[email protected] | ||
with: | ||
version: v3.12.1 | ||
- uses: helm/[email protected] | ||
- id: list-changed | ||
run: | | ||
changed=$(ct list-changed --config=.ct.yml --target-branch ${{ github.event.repository.default_branch }}) | ||
if [[ -n "$changed" ]]; then | ||
echo "changed=true" >> "$GITHUB_OUTPUT" | ||
fi | ||
- if: steps.list-changed.outputs.changed == 'true' | ||
run: ct lint --config=.ct.yml --target-branch ${{ github.event.repository.default_branch }} | ||
- if: steps.list-changed.outputs.changed == 'true' | ||
uses: helm/[email protected] | ||
with: | ||
node_image: kindest/node:v1.29.0 | ||
- if: steps.list-changed.outputs.changed == 'true' | ||
run: ct install --target-branch ${{ github.event.repository.default_branch }} | ||
|
||
release: | ||
name: Helm chart release | ||
runs-on: ubuntu-latest | ||
needs: [ 'lint-test' ] | ||
permissions: | ||
contents: write | ||
steps: | ||
- name: Check out repository | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Git user | ||
run: | | ||
git config user.name "$GITHUB_ACTOR" | ||
git config user.email "[email protected]" | ||
- name: Set up Helm | ||
uses: azure/[email protected] | ||
with: | ||
version: v3.12.1 | ||
|
||
- name: Run chart-releaser | ||
uses: helm/[email protected] | ||
with: | ||
skip_existing: true | ||
mark_as_latest: true | ||
env: | ||
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" |