Skip to content

Commit

Permalink
migrate pull request workflow as well
Browse files Browse the repository at this point in the history
Signed-off-by: Bugen Zhao <[email protected]>
  • Loading branch information
BugenZhao committed Nov 27, 2024
1 parent fbbbb90 commit 985cb45
Showing 1 changed file with 27 additions and 23 deletions.
50 changes: 27 additions & 23 deletions ci/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,31 @@ cargo-cache: &cargo-cache
- ".cargo/git"

other-sql-backend: &other-sql-backend
setup:
label: [""]
endpoint: [""]
adjustments:
- with:
label: ""
endpoint: ""
skip: true # hack
- with:
label: "postgres"
# PGPASSWORD=postgres psql -h db -p 5432 -U postgres -d rwmeta
endpoint: "postgres://postgres:postgres@db:5432/rwmeta"
- with:
label: "mysql"
# mysql -h mysql -P 3306 -u root -p123456 -D rwmeta
endpoint: "mysql://root:123456@mysql:3306/rwmeta"

sql-backend-env: &sql-backend-env
- "RISEDEV_SQL_ENDPOINT={{matrix.endpoint}}"
matrix:
setup:
label: [""]
endpoint: [""]
adjustments:
- with:
label: ""
endpoint: ""
skip: true # hack
- with:
label: "postgres"
# PGPASSWORD=postgres psql -h db -p 5432 -U postgres -d rwmeta
endpoint: "postgres://postgres:postgres@db:5432/rwmeta"
- with:
label: "mysql"
# mysql -h mysql -P 3306 -u root -p123456 -D rwmeta
endpoint: "mysql://root:123456@mysql:3306/rwmeta"
env:
RISEDEV_SQL_ENDPOINT: "{{matrix.endpoint}}"

docker-compose-common: &docker-compose-common
config: ci/docker-compose.yml
mount-buildkite-agent: true
propagate-environment: true
run: rw-build-env

steps:
- label: "check ci image rebuild"
Expand Down Expand Up @@ -811,7 +817,7 @@ steps:
retry: *auto-retry

- label: "end-to-end test ({{matrix.label}} backend)"
matrix: *other-sql-backend
<<: *other-sql-backend
command: "ci/scripts/e2e-test.sh -p ci-dev -m ci-3streaming-2serving-3fe"
if: build.pull_request.labels includes "ci/run-e2e-test-other-backends" || build.env("CI_STEPS") =~ /(^|,)e2e-test-other-backends?(,|$$)/
depends_on:
Expand All @@ -820,10 +826,8 @@ steps:
- "docslt"
plugins:
- docker-compose#v5.1.0:
<<: *docker-compose-common
run: pg-mysql-backend-test-env
config: ci/docker-compose.yml
mount-buildkite-agent: true
env: *sql-backend-env
- ./ci/plugins/upload-failure-logs
timeout_in_minutes: 32
retry: *auto-retry
Expand Down

0 comments on commit 985cb45

Please sign in to comment.