Skip to content

helm chart migrated to calver #311

helm chart migrated to calver

helm chart migrated to calver #311

name: Build Self Contained Image
permissions:
contents: write
packages: write
'on':
workflow_dispatch: {}
push:
branches:
- main
paths:
- '**/*'
- '!.github/badges/*'
- '!README.md'
- '!python/**/*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v0.9.15
with:
versionSpec: 5.x
- id: determine_version
name: Determine Version
uses: gittools/actions/gitversion/execute@v0.9.15
with:
additionalArguments: /overrideconfig mode=Mainline
- name: Get branch name
id: branch-name
uses: tj-actions/branch-names@v7
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
# The Docker image used to run workers
- name: Build, tag, and push worker image to Dockerhub
if: ${{ steps.branch-name.outputs.current_branch == 'main' }}
run: |
docker build -f docker/selfcontained/Dockerfile -t octopussamples/octopub-selfcontained:${{ steps.determine_version.outputs.semVer }} .
docker push octopussamples/octopub-selfcontained:${{ steps.determine_version.outputs.semVer }}
docker tag octopussamples/octopub-selfcontained:${{ steps.determine_version.outputs.semVer }} octopussamples/octopub-selfcontained:latest
docker push octopussamples/octopub-selfcontained:latest
shell: bash