Repository navigation
63 lines (56 loc) · 2.03 KB
/
Copy pathcopilot-setup-steps.yml
File metadata and controls
63 lines (56 loc) · 2.03 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
name: "Copilot Setup Steps"
on:
workflow_dispatch:
push:
paths:
- .github/workflows/copilot-setup-steps.yml
pull_request:
paths:
- .github/workflows/copilot-setup-steps.yml
jobs:
copilot-setup-steps:
# Fork PRs get no secrets, so they can't pull the private mock-server image.
# Without this the job template fails to prepare (empty
# `credentials.password`) the first time an external contributor edits this
# file — the same failure codspeed.yml hit. Same condition as e2e.yml.
if: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }}
runs-on: ubuntu-latest
permissions:
contents: read
services:
mock-server:
# Generated from .github/bartender-image.txt by
# cargo xt ci sync-bartender-image.
image: ghcr.io/whiskeysockets-devtools/bartender@sha256:9f3a49dd9f944414fbda50571bba5f66f2ab6fdc48001e6803d4c09a1042c78e
credentials:
username: ${{ github.actor }}
password: ${{ secrets.BARTENDER_GHCR_TOKEN }}
ports:
- 8080:8080
env:
CHATSTATE_TTL_SECS: "3"
options: --log-driver none
steps:
- name: Checkout code
uses: actions/checkout@v7
- name: Set up Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2026-06-16
- name: Cache install-action tools
uses: actions/cache@v6
with:
path: |
~/.install-action
key: ${{ runner.os }}-install-action-${{ hashFiles('.github/workflows/copilot-setup-steps.yml') }}
restore-keys: |
${{ runner.os }}-install-action-
- name: Cache Rust dependencies
uses: Swatinem/rust-cache@v2
- name: Fetch Rust dependencies
run: cargo fetch
- name: Wait for mock server
run: cargo xt ci workflow wait-for-mock
- name: Export mock server URL
run: |
echo "MOCK_SERVER_URL=wss://127.0.0.1:8080/ws/chat" >> "$GITHUB_ENV"