Repository navigation
144 lines (128 loc) · 5.07 KB
/
Copy pathc-cpp.yml
File metadata and controls
144 lines (128 loc) · 5.07 KB
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
142
143
144
name: CI
on:
push:
branches: ["main"]
tags: ["v*"]
pull_request:
branches: ["main"]
jobs:
media:
name: Linux release music and runtime packaging
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v4
- name: Build Linux dependency environment
run: docker build --tag openrealm-media-ci .github/docker/ci
- name: Build and verify the release media package
run: |
docker run --rm --mount "type=bind,source=$PWD,target=/workspace" \
--workdir /workspace openrealm-media-ci bash -ec '
make BUILD=release FFMPEG=1 BIN_DIR=build/media/bin LIB_DIR=build/media/lib SHARE_INSTALL=build/media/share openwarcraft3
make BUILD=release BIN_DIR=build/media/bin LIB_DIR=build/media/lib test-sound
mkdir -p build/media/package/bin build/media/package/lib
cp build/media/bin/openwarcraft3 build/media/package/bin/
cp build/media/lib/*.so build/media/package/lib/
python3 dist-scripts/linux/bundle_media.py build/media/bin/openwarcraft3 build/media/package/lib
ldd build/media/package/bin/openwarcraft3 > build/media/package/dependencies.txt
cat build/media/package/dependencies.txt
! grep -q "not found" build/media/package/dependencies.txt
'
eos:
name: EOS regressions and live multiplayer checks
# Fork PRs cannot read the licensed SDK/player credentials. Run their normal
# SDK-free checks; never execute fork code through pull_request_target.
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
timeout-minutes: 25
permissions:
contents: read
packages: read
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- name: Fetch the pinned private EOS SDK archive
uses: actions/checkout@v4
with:
repository: ${{ vars.EOS_SDK_REPOSITORY }}
ref: ${{ vars.EOS_SDK_REF }}
ssh-key: ${{ secrets.EOS_SDK_DEPLOY_KEY }}
persist-credentials: false
path: data/eos-archive
- name: Verify SDK and prepare restricted player config
env:
OPENREALM_EOS_PRODUCT_ID: ${{ secrets.OPENREALM_EOS_PRODUCT_ID }}
OPENREALM_EOS_SANDBOX_ID: ${{ secrets.OPENREALM_EOS_SANDBOX_ID }}
OPENREALM_EOS_DEPLOYMENT_ID: ${{ secrets.OPENREALM_EOS_DEPLOYMENT_ID }}
OPENREALM_EOS_CLIENT_ID: ${{ secrets.OPENREALM_EOS_CLIENT_ID }}
OPENREALM_EOS_CLIENT_SECRET: ${{ secrets.OPENREALM_EOS_CLIENT_SECRET }}
run: python3 dist-scripts/eos/prepare_release.py --platform Linux --archive data/eos-archive/EOS-SDK-1.19.2.1-CL58105819-runtime.zip
- name: Pull Linux test environment
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_ACTOR: ${{ github.actor }}
run: |
printf '%s' "$GH_TOKEN" | docker login ghcr.io --username "$GH_ACTOR" --password-stdin
docker pull ghcr.io/corepunch/open-realm-ci:ubuntu-24.04
docker logout ghcr.io
# Include PR dependency changes and software GL for the actual client.
# Dependency installation stays in the shared image Dockerfile.
docker build --tag openrealm-eos-ci .github/docker/ci
- name: Run full EOS-enabled suite
run: >-
docker run --rm --mount "type=bind,source=$PWD,target=/workspace"
--workdir /workspace openrealm-eos-ci
make EOS=1 TEST_JOBS=4 test
- name: Check live login, gameplay, relay, graceful leave and host crash
env:
EOS_RUN_ID: ${{ github.run_id }}-${{ github.run_attempt }}
run: python3 dist-scripts/eos/run_acceptance.py --image openrealm-eos-ci --run-id "$EOS_RUN_ID"
notifications:
name: Discord notification fixtures
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- run: python3 tests/test_discord_notifications.py
test:
runs-on: ubuntu-latest
container:
image: ghcr.io/corepunch/open-realm-ci:ubuntu-24.04
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: read
packages: read
steps:
- uses: actions/checkout@v4
- name: Run unit tests
run: make test
build:
runs-on: ubuntu-latest
container:
image: ghcr.io/corepunch/open-realm-ci:ubuntu-24.04
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: read
packages: read
steps:
- uses: actions/checkout@v4
- name: Build
run: make
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: openwarcraft3-linux-x64
path: |
build/bin/openwarcraft3
build/lib/
build/share/
if-no-files-found: error