generated from kedacore/github-template
-
Notifications
You must be signed in to change notification settings - Fork 9
53 lines (42 loc) · 1.3 KB
/
pr-build.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
46
47
48
49
50
51
52
53
name: Pull request build
on:
pull_request:
branches:
- main
env:
VERSION_TAG: experimental
jobs:
build:
name: Build
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup dotnet environment
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8
- name: Install dependencies
run: dotnet restore src
- name: Build solution
run: dotnet build src --configuration Release --no-restore
- name: Run unit tests
run: dotnet test src --no-restore
- name: Build Docker image for order-generator
uses: docker/build-push-action@v6
with:
file: ./src/Scaler.Demo/OrderGenerator/Dockerfile
tags: cosmosdb-order-generator:${{ env.VERSION_TAG }}
- name: Build Docker image for order-processor
uses: docker/build-push-action@v6
with:
file: ./src/Scaler.Demo/OrderProcessor/Dockerfile
tags: cosmosdb-order-processor:${{ env.VERSION_TAG }}
- name: Build Docker image for scaler
uses: docker/build-push-action@v6
with:
file: ./src/Scaler/Dockerfile
tags: cosmosdb-scaler:${{ env.VERSION_TAG }}