Skip to content

Commit 57d5903

Browse files
authored
Add support for releasing specific runtime/driver version (#968)
* Add support for releasing specific runtime/driver version * debug * only check out action branch * Revert "debug" This reverts commit 32bbd58. * add driverRevision to playwright builds * add description to inputs * trailing newline
1 parent 1aeb1f7 commit 57d5903

File tree

3 files changed

+19
-7
lines changed

3 files changed

+19
-7
lines changed

.github/actions/release/main.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ const {
77
newTask,
88
} = require("../utils");
99

10-
const replayRevision = getLatestReplayRevision();
11-
const playwrightRevision = getLatestPlaywrightRevision();
10+
const replayRevision = process.env.INPUT_RUNTIME_REVISION || getLatestReplayRevision();
11+
const playwrightRevision = process.env.INPUT_PLAYWRIGHT_REVISION || getLatestPlaywrightRevision();
1212

1313
sendBuildTestRequest({
1414
name: `Gecko Release ${replayRevision}`,
@@ -26,6 +26,7 @@ function platformTasks(platform) {
2626
kind: "ReleaseRuntime",
2727
runtime: "gecko",
2828
revision: replayRevision,
29+
driverRevision: process.env.INPUT_DRIVER_REVISION,
2930
},
3031
platform
3132
);
@@ -40,6 +41,7 @@ function platformTasks(platform) {
4041
kind: "ReleaseRuntime",
4142
runtime: "geckoPlaywright",
4243
revision: playwrightRevision,
44+
driverRevision: process.env.INPUT_DRIVER_REVISION
4345
},
4446
platform
4547
);

.github/actions/utils.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ function getLatestPlaywrightRevision() {
2020
function sendBuildTestRequest(contents) {
2121
const text = JSON.stringify(contents);
2222

23+
console.log("Sending Task", JSON.stringify(contents, undefined, 2));
24+
2325
const headers = {
2426
"Content-Type": "application/json",
2527
"Content-Length": text.length,

.github/workflows/release.yml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
11
name: Release Latest Browsers
22
on:
33
workflow_dispatch:
4+
inputs:
5+
runtime_sha:
6+
description: (Optional) 12 char SHA of gecko-dev
7+
type: string
8+
playwright_sha:
9+
description: (Optional) 12 char SHA of playwright branch of gecko-dev
10+
type: string
11+
driver_sha:
12+
description: (Optional) 12 char SHA of driver
13+
type: string
414

515
jobs:
616
release:
@@ -14,14 +24,12 @@ jobs:
1424
authkey: ${{ secrets.TAILSCALE_API_KEY }}
1525
version: "1.38.4"
1626
- uses: actions/checkout@v2
17-
with:
18-
ref: replay-playwright
19-
- uses: actions/checkout@v2
20-
with:
21-
ref: webreplay-release
2227
- uses: ./.github/actions/release
2328
env:
2429
BUILD_TEST_AUTHORIZATION: ${{ secrets.BUILD_TEST_AUTHORIZATION }}
2530
BUILD_TEST_HOSTNAME: a49855c191a944333918aea7ad31bc76-6a8a830d89921d8a.elb.us-east-2.amazonaws.com
2631
BUILD_TEST_PORT: ${{ secrets.BUILD_TEST_PORT }}
2732
BUILD_TEST_INSECURE: ${{ secrets.BUILD_TEST_INSECURE }}
33+
INPUT_RUNTIME_REVISION: ${{ inputs.runtime_sha }}
34+
INPUT_PLAYWRIGHT_REVISION: ${{ inputs.playwright_sha }}
35+
INPUT_DRIVER_REVISION: ${{ inputs.driver_sha }}

0 commit comments

Comments
 (0)