Commands / kosa8 cloud pipelines hook create
kosa8 cloud pipelines hook create
Make a webhook URL for a repository (and optionally a cron schedule)
Usage
kosa8 cloud pipelines hook create REPO_URL
Prints the webhook URL and its signing secret, once: add both to the repository's webhooks (GitHub: Settings > Webhooks, content type JSON, push and pull request events; GitLab: X-Gitlab-Token). kosa8 makes the secret unless --secret-stdin reads yours. --cron also runs it on that schedule (UTC).
Options
| Flag | Type | What it does | Default |
|---|---|---|---|
--cron | string | also run on this cron schedule (UTC) | — |
--cron-ref | string | the ref a scheduled run builds (default: the default branch) | — |
--name | string | a name for the hook | — |
--provider | string | github or gitlab (default: from the URL) | — |
--secret | stringArray | hand this secret (marked --pipelines) to the jobs (repeatable) | [] |
--secret-stdin | bool | read the webhook signing secret from stdin instead of making one | — |
--size | string | sandbox size for each job, e.g. 4x8 | — |
--status-secret | string | the secret that posts commit statuses | — |
--timeout | duration | stop each run after this long | 0s |
--token-secret | string | the secret that clones a private repository | — |
--workflow | string | only this file in .github/workflows | — |
Example
kosa8 cloud pipelines hook create https://github.com/acme/app --secret npm-token kosa8 cloud pipelines hook create https://gitlab.com/acme/app --cron '0 3 * * *' --cron-ref main