|
| 1 | +# Overview |
| 2 | + |
| 3 | +Our CI workflows make heavy usage of [Reusable Workflows](https://docs.github.com/en/actions/using-workflows/reusing-workflows). These reusable workflows can then be tested manually via the `manual_dispatch.yml` workflow. |
| 4 | +Or integrated into CI jobs such has `on_pull_request.yml` or `on_main.yml`. |
| 5 | + |
| 6 | +By convention: |
| 7 | +- All reusable workflows start with the `reusable_` prefix. |
| 8 | +- All workflows that are triggered via `workflow_dispatch` start with the `manual_` prefix. |
| 9 | +- All workflows that are triggered via an event start with the `on_` prefix. |
| 10 | + - `on_pull_request` is triggered on pull requests. |
| 11 | + - `on_main` is triggered on pushes to the main branch. |
| 12 | + |
| 13 | +If you are going to be doing any editing of workflows, the |
| 14 | +[VS Code extension](https://marketplace.visualstudio.com/items?itemName=cschleiden.vscode-github-actions) |
| 15 | +for GitHub Actions is highly recommended. |
| 16 | + |
| 17 | +## Reusable Workflows |
| 18 | +- [reusable_checks.yml](reusable_checks.yml) - These are all the checks that run to ensure the code is formatted, |
| 19 | + linted, and tested. This job produces no artifacts other than a pass/fail criteria for the build. |
| 20 | + - `SAVE_CACHE` - If true, the rust cache will be saved. Generally we only do this for builds on `main` |
| 21 | +- [reusable_bench.yml](reusable_bench.yml) - This job runs the benchmarks to check for performance regressions. |
| 22 | + - `SAVE_BENCH` - If true, then the benchmark results are saved to update https://ref.rerun.io/dev/bench/ |
| 23 | +- [reusable_deploy_docs](reusable_deploy_docs.yml) - This job deploys the python and rust documentation to https://ref.rerun.io |
| 24 | + - `PY_DOCS_VERSION_NAME` - The name to use for versioning the python docs. This should generally match the version in |
| 25 | + `Cargo.toml`. |
| 26 | + - `UPDATE_LATEST` - If true, then the docs will be deployed to `latest/` as well as the versioned directory. |
| 27 | +- [reusable_build_and_test_wheels.yml](reusable_build_and_test_wheels.yml) - This job builds the wheels, runs the |
| 28 | +end-to-end test, and produces a sample RRD. The artifacts are accessible via GitHub artifacts, but not otherwise |
| 29 | +uploaded anywhere. |
| 30 | + - `MATURIN_FEATURE_FLAGS` - The feature flags to pass to maturin. |
| 31 | + - `PLATFORM` - Which platform to build for: `linux`, `macos-arm`, `macos-intel`, or `windows`. |
| 32 | + - `RELEASE_VERSION` - If producing a release, the version number. This must match the version in `Cargo.toml`. |
| 33 | + - `RRD_ARTIFACT_NAME` - Intermediate name of the GitHub rrd artifact for passing to `reusable_upload_wheels.yml` |
| 34 | + - `SAVE_CACHE` - If true, the rust cache will be saved. Generally we only do this for builds on `main` |
| 35 | + - `WHEEL_ARTIFACT_NAME` - Intermediate name of the GitHub wheel artifact for passing to `reusable_upload_wheels.yml` |
| 36 | +- [reusable_upload_wheels.yml](reusable_upload_wheels.yml) - This job uploads the wheels to google cloud |
| 37 | + - `RRD_ARTIFACT_NAME` - Intermediate name of the GitHub rrd artifact. This should match the name passed to |
| 38 | + `reusable_build_and_test_wheels.yml` |
| 39 | + - `WHEEL_ARTIFACT_NAME` - Intermediate name of the GitHub wheel artifact. This should match the name passed to |
| 40 | + `reusable_build_and_test_wheels.yml` |
| 41 | +- [reusable_build_web.yml](reusable_build_web.yml) - This job builds the wasm artifacts for the web. |
| 42 | + - `RELEASE_VERSION` - If producing a release, the version number. This must match the version in `Cargo.toml`. |
| 43 | +- [reusable_upload_web.yml](reusable_upload_web.yml) - This job uploads the web assets to google cloud. By default this |
| 44 | + only uploads to: `app.rerun.io/commit/<commit>/` |
| 45 | + - `MARK_PRERELEASE_FOR_MAINLINE` - If true, then the web assets will go to `app.rerun.io/preleease/ |
| 46 | + - `MARK_TAGGED_VERSION` - If true, then the web assets will go to `app.rerun.io/version/<RELEASE_VERSION>` |
| 47 | + - `RELEASE_VERSION` - If producing a release, the version number. |
| 48 | + - `RRD_ARTIFACT_NAME` - Intermediate name of the GitHub rrd artifact. This should match the name passed to |
| 49 | + `reusable_build_and_test_wheels.yml` |
| 50 | + - `UPLOAD_COMMIT_OVERRIDE` - If set, will replace the value of `<commit>`. This is necessary because we want pull |
| 51 | + request builds associated with their originating commit, even if the web-build happens on an ephemeral merge-commit. |
| 52 | +- [reusable_pr_summary.yml](reusable_pr_summary.yml) - This job updates the PR summary with the results of the CI run. |
| 53 | + - This summary can be found at: |
| 54 | + `https://storage.googleapis.com/rerun-builds/pull_request/<PR_NUMBER>/index.html` |
| 55 | + - `PR_NUMBER` - The PR number to update. This will generally be set by the `on_pull_request.yml` workflow using: |
| 56 | + `${{github.event.pull_request.number}}` |
| 57 | + |
| 58 | +## Manual Workflows |
| 59 | +- [manual_dispatch](manual_dispatch.yml) - This workflow is used to manually trigger the assorted reusable workflows for |
| 60 | + testing. |
| 61 | + - See the workflow file for the list of parameters. |
| 62 | +- [manual_build_wheels_for_pr.yml](manual_build_wheels_for_pr.yml) - This workflow can be dispatched on a branch and |
| 63 | + will build all of the wheels for the associated pull-request. Uses: |
| 64 | + - [reusable_build_and_test_wheels.yml](reusable_build_and_test_wheels.yml) |
| 65 | + - [reusable_upload_wheels.yml](reusable_upload_wheels.yml) |
| 66 | + - [reusable_pr_summary.yml](reusable_pr_summary.yml) |
0 commit comments