Skip to content

Workflow file for this run

name: on-push-to-main
concurrency:
group: on-push-to-main
cancel-in-progress: true
on:
push:
branches:
- '*' # TODO - master
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET 8.x
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.x'
# - name: Install dependencies
# run: npm install --prefix ./Code/src/WeatherStationProject.Dashboard.App/ClientApp install --force && dotnet restore ./Code/WeatherStationProjectDashboard.sln
# - name: Build
# run: dotnet build ./Code/WeatherStationProjectDashboard.sln
# - name: Test with the dotnet CLI
# run: dotnet test
- name: Log in to Docker Hub
uses: docker/login-action@v3.3.0
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Extract metadata for the Dashboard
id: metaDashboard
uses: docker/metadata-action@v5.5.1
with:
images: weatherstationproject/dashboard
- name: Build and push Dashboard
id: push
uses: docker/build-push-action@v6.9.0
with:
context: .
build-args: |
"INCLUDE_NPM_ARG=true"
"PROJECT_NAME_ARG=WeatherStationProject.Dashboard.App"
"ENVIRONMENT_ARG=Production"
file: ./Dockerfile
push: true
tags: ${{ steps.metaDashboard.outputs.tags }}
labels: ${{ steps.metaDashboard.outputs.labels }}