30 lines
953 B
YAML
30 lines
953 B
YAML
name: Build and Push
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
branches:
|
|
- master
|
|
- releases/*
|
|
|
|
jobs:
|
|
push:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: catthehacker/ubuntu:act-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0 # all history for all branches and tags
|
|
- name: Install Helm
|
|
run: curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash
|
|
- name: pack helm release
|
|
run: helm package .
|
|
- name: Get Package Name
|
|
id: meta
|
|
run: echo PACKAGE_NAME=$(ls | grep .tgz) >> $GITHUB_OUTPUT
|
|
- run: echo "${{ env.HELM_REPO }} ${{ secrets.HELM_USER }}. Today is ${{ steps.meta.outputs.PACKAGE_NAME }}!"
|
|
- name: Push to Package Repo
|
|
run: curl --user ${{ secrets.HELM_USER }}:${{ secrets.HELM_PASSWD }} -X POST --upload-file ./${{ steps.meta.outputs.PACKAGE_NAME }} ${{ env.HELM_REPO }}
|