From 5361f8de1552199ce5b2af87151603d59e94e703 Mon Sep 17 00:00:00 2001 From: "Zhian N. Kamvar" Date: Fri, 2 Aug 2024 12:20:23 -0700 Subject: [PATCH] add documenation about validate-config action This satisfies https://github.com/hubverse-org/hubverse-actions/pull/20#pullrequestreview-2214770511 --- .../continuous-integration.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/docs/source/quickstart-hub-admin/continuous-integration.md b/docs/source/quickstart-hub-admin/continuous-integration.md index 4cc79e41..b17df1d8 100644 --- a/docs/source/quickstart-hub-admin/continuous-integration.md +++ b/docs/source/quickstart-hub-admin/continuous-integration.md @@ -20,6 +20,7 @@ remotes::install_github("hubverse-org/hubCI") The [`hubverse-actions`](https://github.com/hubverse-org/hubverse-actions) repository currently contains directories with templates related to the following workflows: * [`cache-hubval-deps`](https://github.com/hubverse-org/hubverse-actions/tree/main/cache-hubval-deps) +* [`validate-config`](https://github.com/hubverse-org/hubverse-actions/tree/main/validate-config) * [`validate-submission`](https://github.com/hubverse-org/hubverse-actions/tree/main/validate-submission) * [`hubverse-aws-upload`](https://github.com/hubverse-org/hubverse-actions/tree/main/hubverse-aws-upload) @@ -55,6 +56,20 @@ The action is triggered by pull requests onto the `main` branch that add or modi More information can be found [here](https://github.com/hubverse-org/hubverse-actions/tree/main/validate-submission) as well as in the hubValidations vignette on [Validating Pull Requests on GitHub](https://hubverse-org.github.io/hubValidations/articles/validate-pr.html). +### [`validate-config`](https://github.com/hubverse-org/hubverse-actions/tree/main/validate-config) + +This hubverse action installs the `hubAdmin` package from GitHub using pak as well as required system dependencies. + +It then performs submission validation checks through function `hubAdmin::validate_hub_config()` and assumes you have all three of the required configuration JSON files in your `hub-config/` directory: + + - `admin.json` + - `model-metadata-schema.json` + - `tasks.json` + +When invalid config files are discovered, a GitHub comment is created (or updated) with a table containing information about the exact locations of the failures using the [`hubAdmin::view_config_val_errors()`](https://hubverse-org.github.io/hubAdmin/reference/view_config_val_errors.html) function. + +The action is triggered by pull requests onto the `main` branch which add or modify files in the `hub-config/` directory. For hubs and repositories which differ in configuration, workflow dispatch will need to be customised manually in the hubs workflow file. + ### [`hubverse-aws-upload`](https://github.com/hubverse-org/hubverse-actions/tree/main/hubverse-aws-upload) This action uploads your hub data to hubverse-hosted cloud storage. Currently, the workflow has a single job, `upload`, that pushes data to an Amazon Web Services (AWS) Simple Storage Service (S3) bucket. The `upload` job inspects the hub's admin config (`admin.json`) for a `cloud` group. If cloud is enabled (i.e., if `cloud.enabled` is set to `true`), the job: