Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: MicrosoftDocs/mslearn-microservices-devops-aspnet-core
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: dev-ojeda/mslearn-microservices-devops-aspnet-core
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Able to merge. These branches can be automatically merged.
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Nov 30, 2023

  1. Create build.yml

    dev-ojeda authored Nov 30, 2023

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    1ed97db View commit details
Showing with 35 additions and 0 deletions.
  1. +35 −0 .github/workflows/build.yml
35 changes: 35 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: eShop build

on:
push:
paths:
- 'src/Services/Coupon/**'
- 'tests/Services/Coupon/**'
branches: [ main ]

jobs:
build-and-push-docker-image:
runs-on: ubuntu-latest
steps:
- name: Get code from the repository
uses: actions/checkout@v1
with:
ref: main

- name: Run unit tests
run: dotnet test tests/Services/Coupon/*.Tests/*.csproj
env:
DOTNET_CLI_TELEMETRY_OPTOUT: true
DOTNET_NOLOGO: true

- name: Build and push Docker image
uses: docker/build-push-action@v1.1.0
with:
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
registry: ${{ secrets.REGISTRY_LOGIN_SERVER }}
path: .
dockerfile: './src/Services/Coupon/Coupon.API/Dockerfile.acr'
repository: 'coupon.api'
tags: 'linux-net6-coupon'
push: true