Skip to content

Commit

Permalink
checkout PR and reuse in subsequent workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
zainasir committed Jan 7, 2025
1 parent 37a07b0 commit 2b304b5
Showing 1 changed file with 16 additions and 6 deletions.
22 changes: 16 additions & 6 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,19 @@ jobs:
paths:
- cbioportal-frontend

checkout_pr:
machine:
image: ubuntu-2204:2024.08.1
resource_class: medium
working_directory: /tmp/repos
steps:
- checkout:
path: /tmp/repos/cbioportal
- persist_to_workspace:
root: /tmp/repos
paths:
- cbioportal

build_image:
machine:
image: ubuntu-2204:2024.08.1
Expand All @@ -302,8 +315,6 @@ jobs:
steps:
- attach_workspace:
at: /tmp/repos
- checkout:
path: /tmp/repos/cbioportal
- build_push_image:
push: "false"
- run:
Expand All @@ -324,8 +335,6 @@ jobs:
steps:
- attach_workspace:
at: /tmp/repos
- checkout:
path: /tmp/repos/cbioportal
- build_push_image:
push: "true"

Expand All @@ -340,8 +349,6 @@ jobs:
steps:
- attach_workspace:
at: /tmp/repos
- checkout:
path: /tmp/repos/cbioportal
- run:
name: Load cbioportal image
command: |
Expand Down Expand Up @@ -455,16 +462,19 @@ workflows:
- install_yarn
tests:
jobs:
- checkout_pr
- pull_cbioportal_test_codebase
- pull_cbioportal_frontend_codebase
- build_image:
requires:
- checkout_pr
- pull_cbioportal_test_codebase
- pull_cbioportal_frontend_codebase
- push_image:
context:
- api-tests
requires:
- checkout_pr
- pull_cbioportal_test_codebase
- pull_cbioportal_frontend_codebase
- run_api_tests:
Expand Down

0 comments on commit 2b304b5

Please sign in to comment.