-
Notifications
You must be signed in to change notification settings - Fork 23
35 lines (32 loc) · 892 Bytes
/
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
name: CI
on:
push:
pull_request:
branches:
- main
jobs:
"test":
runs-on: ubuntu-latest
services:
redis:
image: redis
ports:
- 6379:6379
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v1
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
- name: Build
run: dotnet build --configuration Release -p:ContinuousIntegrationBuild=true
- name: Test
run: dotnet test --no-build --configuration Release --no-build --framework net7.0
env:
REDIS_HOST: localhost
REDIS_PORT: ${{ job.services.redis.ports[6379] }}
- name: Pack
run: dotnet pack --no-build --configuration Release -p:ContinuousIntegrationBuild=true