fix: WhatIfParser
shouldn't fail if there's no TemplateParser
#123
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: Build & Push Docker image | |
on: | |
workflow_dispatch: | |
inputs: | |
imageTag: | |
description: 'Tag to be used for the Docker image' | |
required: true | |
type: string | |
push: | |
branches: [ "main", Main ] | |
env: | |
TAG: ${{ inputs.imageTag }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Login to DockerHub | |
run: docker login -u thecloudtheory -p ${{ secrets.DOCKER_HUB_KEY }} | |
- name: Build the Docker image (latest) | |
if: ${{ env.TAG == '' }} | |
run: docker build . --file ./ace/Dockerfile --tag thecloudtheory/azure-cost-estimator:latest | |
- name: Build the Docker image (tag) | |
if: ${{ env.TAG != '' }} | |
run: docker build . --file ./ace/Dockerfile --tag thecloudtheory/azure-cost-estimator:$TAG | |
- name: Tag latest | |
if: ${{ env.TAG != '' }} | |
run: docker tag thecloudtheory/azure-cost-estimator:$TAG thecloudtheory/azure-cost-estimator:latest | |
- name: Push the Docker image | |
if: ${{ env.TAG != '' }} | |
run: docker push thecloudtheory/azure-cost-estimator:$TAG | |
- name: Push the Docker image (latest) | |
if: ${{ env.TAG == '' }} | |
run: docker push thecloudtheory/azure-cost-estimator:latest |