-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (45 loc) · 1.57 KB
/
pr-verification.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: pr-verification
on:
pull_request:
types: [opened, synchronize, reopened]
jobs:
build-extension:
runs-on: ubuntu-latest
env:
DOTNET_NOLOGO: true
DOTNET_CLI_TELEMETRY_OPTOUT: true
RepositoryUrl: 'https://github.com/${{ github.repository }}'
RepositoryBranch: '${{ github.ref }}'
SourceRevisionId: '${{ github.sha }}'
VersionSuffix: 'pr-${{github.event.number}}.${{ github.run_number }}'
Configuration: Release
SolutionPath: ./src/GrpcTestKit.sln
Deterministic: true
PackageReleaseNotes: 'https://github.com/${{ github.repository }}/releases'
ContinuousIntegrationBuild: true
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core 7
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0'
- name: Calculate next version
uses: cezarypiatek/NextVersionGeneratorAction@0.4
with:
minor-pattern: '.*'
major-pattern: 'BREAKING CHANGES'
output-to-env-variable: 'VersionPrefix'
- name: Restore dependencies
run: |
dotnet nuget locals all --clear
dotnet restore ${{ env.SolutionPath }}
- name: Build extension
run: dotnet build ${{ env.SolutionPath }} -maxcpucount:1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Build docker
uses: docker/build-push-action@v4
with:
push: false
context: "{{defaultContext}}:src/"
tags: cezarypiatek/grpc-mock-server:latest,cezarypiatek/grpc-mock-server:${{ env.VersionPrefix }}