feat: Add support for mounting extra volumes and add webhook URL override capability #33
Workflow file for this run
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
name: Publish Release | |
on: | |
release: | |
types: [created] | |
pull_request: | |
branches: | |
- main | |
paths: | |
- "**.go" | |
- "hack/test.sh" | |
- ".github/workflows/release.yaml" | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Set up Go 1.17 | |
uses: actions/setup-go@v1 | |
with: | |
go-version: 1.17 | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v1 | |
- name: Test | |
run: ./hack/test.sh | |
release: | |
if: startsWith(github.ref, 'refs/tags/v') == true | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Get Docker tags | |
id: docker_meta | |
uses: crazy-max/ghaction-docker-meta@v2 | |
with: | |
images: | | |
loftsh/jspolicy | |
tags: | | |
type=semver,pattern={{version}} | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v1 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v1 | |
- name: Login to DockerHub | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build and push the Debian based image | |
id: docker_build | |
uses: docker/build-push-action@v2 | |
with: | |
file: Dockerfile | |
platforms: linux/amd64 | |
push: true | |
tags: ${{ steps.docker_meta.outputs.tags }} | |
labels: ${{ steps.docker_meta.outputs.labels }} | |
- name: Images digests | |
run: echo ${{ steps.docker_build.outputs.digest }} | |
- uses: azure/setup-helm@v1 | |
with: | |
version: "v3.0.3" | |
- run: | | |
RELEASE_VERSION=$(echo $GITHUB_REF | sed -nE 's!refs/tags/v!!p') | |
helm plugin install https://github.com/chartmuseum/helm-push | |
helm repo add chartmuseum $CHART_MUSEUM_URL --username $CHART_MUSEUM_USER --password $CHART_MUSEUM_PASSWORD | |
helm cm-push --force --version="$RELEASE_VERSION" ./chart chartmuseum | |
env: | |
CHART_MUSEUM_URL: "https://charts.devspace.sh/" | |
CHART_MUSEUM_USER: ${{ secrets.CHART_MUSEUM_USER }} | |
CHART_MUSEUM_PASSWORD: ${{ secrets.CHART_MUSEUM_PASSWORD }} |