Skip to content

containerization of react app #38

containerization of react app

containerization of react app #38

Workflow file for this run

name: .NET
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore ./api/api.csproj
- name: Build
run: dotnet build --no-restore ./api/api.csproj -c Release
- name: Publish
run: dotnet publish --no-build ./api/api.csproj -c Release -o ./api/out
# Publishing to Docker HUB
#- name: Build and Push Docker Image
# uses: mr-smithers-excellent/docker-build-push@v4
# with:
# image: wombir/finshark-api
# registry: docker.io
# dockerfile: ./api/Dockerfile
# username: ${{ secrets.DOCKER_USERNAME }}
# password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and Push Docker Image to GCP
uses: mr-smithers-excellent/docker-build-push@v6
with:
image: finshark/finsharp-api
registry: gcr.io
dockerfile: ./api/Dockerfile
username: _json_key
password: ${{ secrets.GCP_SA_KEY }}