-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (41 loc) · 1.16 KB
/
test_deploy.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
name: Test/Deploy
on:
[ pull_request, push ]
jobs:
code_analysis:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'
- name: Restore
run: dotnet restore
- name: Build
run: dotnet build --no-restore -warnAsError ZipishLens
- name: Inspection
uses: muno92/resharper_inspectcode@v1
with:
solutionPath: ./ZipishLens.sln
exclude: ZipishLens/wwwroot/**
minimumReportSeverity: 'WARNING'
deploy:
needs: [ code_analysis ]
permissions:
contents: read
deployments: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'
- name: Build
run: |
dotnet publish -c Release ZipishLens -o output
- name: Deploy
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
command: pages deploy output/wwwroot --project-name=zipish-lens