Skip to content

Commit

Permalink
chore(ci): publish mkdocs and Helm chart from the specified ref
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Pacak <[email protected]>
  • Loading branch information
danielpacak committed Dec 17, 2021
1 parent 539d3f7 commit 4d58b0b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/mkdocs-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,18 @@ name: Deploy documentation
on:
workflow_dispatch:
inputs:
version:
description: Version to be deployed
ref:
description: The branch, tag or SHA to deploy.
required: true

jobs:
deploy:
name: Deploy documentation
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- name: Checkout main
uses: actions/checkout@v2
with:
ref: ${{ github.event.inputs.ref }}
fetch-depth: 0
persist-credentials: true
- uses: actions/setup-python@v2
Expand All @@ -34,4 +34,4 @@ jobs:
git config user.name "aqua-bot"
git config user.email "[email protected]"
- run: |
mike deploy --push --update-aliases ${{ github.event.inputs.version }} latest
mike deploy --push --update-aliases ${{ github.event.inputs.ref }} latest
10 changes: 7 additions & 3 deletions .github/workflows/publish-helm-chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ name: Publish Helm chart

on:
workflow_dispatch:
inputs:
ref:
description: The branch, tag or SHA to publish.
required: true
env:
HELM_REP: helm-charts
GH_OWNER: aquasecurity
Expand All @@ -16,15 +20,16 @@ jobs:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2.4.0
uses: actions/checkout@v2
with:
ref: ${{ github.event.inputs.ref }}
fetch-depth: 0
- name: Install Helm
uses: azure/setup-helm@18bc76811624f360dbd7f18c2d4ecb32c7b87bab # v1.1
with:
version: v3.5.0
- name: Set up python
uses: actions/setup-python@0066b88440aa9562be742e2c60ee750fc57d8849 # v2.3.0
uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Setup Chart Linting
Expand All @@ -42,7 +47,6 @@ jobs:
wget https://github.com/helm/chart-releaser/releases/download/v1.3.0/chart-releaser_1.3.0_linux_amd64.tar.gz
echo "baed2315a9bb799efb71d512c5198a2a3b8dcd139d7f22f878777cffcd649a37 chart-releaser_1.3.0_linux_amd64.tar.gz" | sha256sum -c -
tar xzvf chart-releaser_1.3.0_linux_amd64.tar.gz cr
- name: Package helm chart
run: |
./cr package ${{ env.CHART_DIR }}
Expand Down

0 comments on commit 4d58b0b

Please sign in to comment.