cma-open / cmascience

Example cma scientific software repo - FOR TRAINING USE
BSD 3-Clause "New" or "Revised" License
0 stars 1 forks source link

SPIKE: Review and test options for multi workflow pipelines #8

Open jonathan-winn-geo opened 4 years ago

jonathan-winn-geo commented 4 years ago

As a system user I want to record the system design options and pipeline / workflow functionality in the wiki so that it can be referred to during maintenance or be used by others when designing other systems

What are the options to create several workflows in the repo, to allow

jonathan-winn-geo commented 4 years ago

https://docs.github.com/en/actions/reference/events-that-trigger-workflows#triggering-new-workflows-using-a-personal-access-token

If you would like to trigger a workflow from a workflow run, you can trigger the event using a personal access token. You'll need to create a personal access token and store it as a secret. To minimize your GitHub Actions usage costs, ensure that you don't create recursive or unintended workflow runs. For more information, see "Creating and storing encrypted secrets."

jonathan-winn-geo commented 4 years ago

Tasks

jonathan-winn-geo commented 4 years ago

https://github.com/asarkar/build-time-tracker/blob/master/.github/workflows/publish.yml

jonathan-winn-geo commented 4 years ago

workflows and events

You can configure your workflows to run when specific activity on GitHub happens, at a scheduled time, or when an event outside of GitHub occurs.

https://docs.github.com/en/actions/reference/events-that-trigger-workflows#workflow_dispatch

"The workflow files for that commit SHA and Git ref are inspected, and a new workflow run is triggered for any workflows that have on: values that match the triggering event."

To trigger specific workflows in a repository, use the workflow_dispatch event. To trigger more than one workflow in a repository and create custom events and event types, use the repository_dispatch event.

You can manually trigger a workflow run using the GitHub API and from GitHub. To trigger the custom workflow_dispatch webhook event using the REST API, you must send a POST request to a GitHub API endpoint and provide the ref and any required inputs. For more information, see the "Create a workflow dispatch event" REST API endpoint.