version 3.0.1 #18
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: Blaze Docker builds | |
on: | |
push: | |
tags: | |
- v* | |
- client-* | |
- server-* | |
jobs: | |
client-image: | |
name: Build and publish Blaze client image | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/client-') | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v2 | |
- name: Get the version | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | |
- name: Login to DockerHub | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build and push | |
uses: docker/build-push-action@v2 | |
with: | |
file: ./client/Dockerfile | |
context: . | |
push: true | |
tags: akashhamirwasia/blaze-client:latest, akashhamirwasia/blaze-client:release-${{ steps.get_version.outputs.VERSION }} | |
server-image: | |
name: Build and publish Blaze server image | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/server-') | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v2 | |
- name: Get the version | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | |
- name: Login to DockerHub | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build and push | |
uses: docker/build-push-action@v2 | |
with: | |
file: ./server/Dockerfile | |
context: . | |
push: true | |
tags: akashhamirwasia/blaze-server:latest, akashhamirwasia/blaze-server:release-${{ steps.get_version.outputs.VERSION }} | |
monolith-image: | |
name: Build and publish Blaze image with both server and client | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/v') | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v2 | |
- name: Get the version | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | |
- name: Login to DockerHub | |
uses: docker/login-action@v1 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Build and push | |
uses: docker/build-push-action@v2 | |
with: | |
file: ./Dockerfile | |
context: . | |
push: true | |
tags: akashhamirwasia/blaze:latest, akashhamirwasia/blaze:release-${{ steps.get_version.outputs.VERSION }} |