Skip to content

adding back everything #40

adding back everything

adding back everything #40

Workflow file for this run

name: .NET Core
on:
push:
# branches: [ develop ]
pull_request:
# branches: [ develop ]
jobs:
build:
runs-on: ubuntu-latest
env:
working-directory: ./src
steps:
- uses: actions/checkout@v3
- name: Setup .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.400
- name: List current directory
run: ls -R
working-directory: ${{env.working-directory}}
- name: Install dependencies
run: dotnet restore
working-directory: ${{env.working-directory}}
- name: Build
run: dotnet build --configuration Release --no-restore
working-directory: ${{env.working-directory}}
- name: Test
run: dotnet test --no-restore --verbosity normal
working-directory: ${{env.working-directory}}
- name: Echo the branch
run: |
echo ${{github.ref}}
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
- name: If-develop, publish docker
uses: docker/build-push-action@v4
with:
push: true
tags: jdevil/mockapiserver:latest
context: ${{env.working-directory}}
file: ${{env.working-directory}}/Dockerfile