Skip to content

HLS streaming and RecomendationAlog full impl, + preparation for depl… #13

HLS streaming and RecomendationAlog full impl, + preparation for depl…

HLS streaming and RecomendationAlog full impl, + preparation for depl… #13

name: Account Build Test N Publish
on:
push:
branches: [ "main" ]
paths:
- 'Backend/Account/**'
pull_request:
branches: [ "main" ]
paths:
- 'Backend/Account/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x
- name: Restore dependencies for Account project
run: dotnet restore Backend/Account/Account.csproj
- name: Restore dependencies for Account Test project
run: dotnet restore Backend/Tests/Account.Test/Account.Test.csproj
- name: Build Account project
run: dotnet build Backend/Account/Account.csproj --no-restore
- name: Build Account Test project
run: dotnet build Backend/Tests/Account.Test/Account.Test.csproj --no-restore
- name: List test assembly path
run: ls -la Backend/Tests/Account.Test/bin/Debug/net8.0/
- name: Run tests
run: dotnet test Backend/Tests/Account.Test/Account.Test.csproj --verbosity normal
- name: Log in to DockerHub
uses: docker/login-action@v1
if: success()
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v2
if: success()
with:
context: ./Backend/
file: Backend/Account/Dockerfile
push: true
tags: openvidstreamer/account:latest