-
Notifications
You must be signed in to change notification settings - Fork 355
55 lines (49 loc) · 1.36 KB
/
ci.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
54
55
name: "CI"
on:
push:
branches:
- main
- features/**
tags:
- '*.*.*'
paths:
- 'identity-server/**'
pull_request:
paths:
- 'identity-server/**'
env:
DOTNET_NOLOGO: true
permissions:
contents: read
jobs:
build:
strategy:
fail-fast: false
matrix:
runs-on: [macOS-latest, ubuntu-latest, windows-latest]
name: ${{ matrix.runs-on }}
runs-on: ${{ matrix.runs-on }}
defaults:
run:
working-directory: identity-server
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup dotnet (main)
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
9.0.x
- run: dotnet --info
- if: contains(matrix.runs-on, 'macOS') || contains(matrix.runs-on, 'ubuntu')
run: ./build.sh
- if: matrix.runs-on == 'windows-latest' && github.ref != 'refs/heads/main' && !contains(github.ref, 'refs/tags/')
run: ./build.ps1
- if: (matrix.runs-on == 'windows-latest') && (github.ref == 'refs/heads/main' || contains(github.ref, 'refs/tags/'))
env:
SignClientSecret: ${{ secrets.SIGNCLIENTSECRET }}
run: |
./build.ps1 sign
dotnet nuget push .\identity-server\artifacts\*.nupkg -s https://www.myget.org/F/duende_identityserver/api/v2/package -k ${{ secrets.MYGET }}