-
Notifications
You must be signed in to change notification settings - Fork 108
141 lines (117 loc) · 4.38 KB
/
healthcheck-streaming.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
name: Check health of streaming
on:
workflow_dispatch:
push:
paths:
- "Common/**"
- "Frontend/**"
- "Signalling/**"
- "SignallingWebServer/**"
- "Extras/**"
pull_request:
paths:
- "Common/**"
- "Frontend/**"
- "Signalling/**"
- "SignallingWebServer/**"
- "Extras/**"
jobs:
# Uncomment when we can Linux test to capture a non-black screenshot using software renderer.
# streaming-test-linux:
# if: github.repository == 'EpicGamesExt/PixelStreamingInfrastructure'
# runs-on: ubuntu-latest
# steps:
# - name: Checkout source code
# uses: actions/checkout@v3
# - name: Create results directory
# run: mkdir Extras/MinimalStreamTester/results
# - name: Launch stream test in docker containers
# uses: isbang/[email protected]
# with:
# compose-file: "Extras/MinimalStreamTester/docker-compose.yml"
# up-flags: "--build --abort-on-container-exit --exit-code-from tester"
# - name: Get short sha
# id: vars
# run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
# - name: Upload results
# uses: actions/upload-artifact@v4
# with:
# name: Results-${{ steps.vars.outputs.sha_short }}-Linux
# path: Extras/MinimalStreamTester/results
streaming-test-win:
if: github.repository == 'EpicGamesExt/PixelStreamingInfrastructure'
runs-on: windows-latest
steps:
- name: Checkout source code
uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: 'v18.17.0'
- name: Download streamer
uses: robinraju/release-downloader@v1
with:
repository: 'EpicGamesExt/PixelStreamingInfrastructure'
tag: 'minimal-streamer'
fileName: 'Minimal-PixelStreamer-5.5.7z'
- name: Extract streamer
run: 7z x -oStreamer Minimal-PixelStreamer-5.5.7z
- name: Build Common
working-directory: Common
run: |
npm install
npm run build
- name: Build Signalling
working-directory: Signalling
run: |
npm install
npm run build
- name: Build Wilbur
working-directory: SignallingWebServer
run: |
npm install
npm run build
- name: Build Frontend lib
working-directory: Frontend/library
run: |
npm install
npm run build
- name: Build Frontend ui lib
working-directory: Frontend/ui-library
run: |
npm install
npm run build
- name: Build Frontend implementation
working-directory: Frontend/implementations/typescript
run: |
$Env:WEBPACK_OUTPUT_PATH='${{ github.workspace }}\www'
npm install
npm run build
- name: Run Signalling
working-directory: SignallingWebServer
run: Start-Process "npm" -ArgumentList "run","start","--","--rest_api","--player_port 999","--http_root ${{ github.workspace }}\www"
- name: Run Streamer
working-directory: Streamer
run: Start-Process ".\Minimal\Binaries\Win64\Minimal-Win64-Shipping-Cmd.exe" -ArgumentList "-warp","-dx12","-windowed","-res=1920","-resy=720","-PixelStreamingURL=ws://localhost:8888","-RenderOffScreen","-AllowSoftwaRerendering","-PixelStreamingEncoderCodec=vp8"
- name: Prepare test
working-directory: Extras\MinimalStreamTester
run: |
npm install
npx playwright install --with-deps
npx playwright install chrome
- name: Wait for signalling to come up
run: curl --retry 10 --retry-delay 20 --retry-connrefused http://localhost:999/api/status
- name: Wait for streamer to come up
run: curl --retry 10 --retry-delay 20 --retry-connrefused http://localhost:999/api/streamers/DefaultStreamer
- name: Test if we can stream
working-directory: Extras\MinimalStreamTester
run: |
$Env:PIXELSTREAMING_URL = 'http://localhost:999'
npx playwright test
- name: Get short sha
id: vars
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $Env:GITHUB_OUTPUT
- name: Upload results
uses: actions/upload-artifact@v4
with:
name: Results-${{ steps.vars.outputs.sha_short }}-Win
path: Extras\MinimalStreamTester\playwright-report