# kosa8 ci connect

Run a connected GitHub repo's pipeline on every push and pull request (no webhook, no token)

## Usage

```
kosa8 ci connect OWNER/NAME
```

Connects a repo of your GitHub connection (kosa8 github repos) to kosa8 Pipelines.
The kosa8 GitHub App delivers its pushes and pull requests, so there is no webhook
to add and no token to store: each run clones it with a read-only token for that
one repo, revoked after the clone, and reports back on the commit as a check run.
Pull requests from forks never run. Needs an admin of this kosa8 organization.
For a repo elsewhere (GitLab, another host): kosa8 cloud pipelines hook create URL.

## Flags

| Flag | Type | What it does | Default |
|---|---|---|---|
| `--cron` | string | also run on this cron schedule (UTC) |  |
| `--cron-ref` | string | the branch a scheduled run builds (default: the default branch) |  |
| `--events` | stringArray | which deliveries start a run: push, pull_request (repeat; default both) | `[]` |
| `--name` | string | a name for the pipeline |  |
| `--secret` | stringArray | hand this secret (marked --pipelines) to the jobs (repeatable) | `[]` |
| `--size` | string | sandbox size for each job, e.g. 4x8 |  |
| `--timeout` | duration | stop each run after this long | `0s` |
| `--workflow` | string | only this file in .github/workflows |  |

## Example

```
  kosa8 ci connect acme/app
  kosa8 ci connect acme/app --events push --size 4x8 --secret npm-token
  kosa8 cloud pipelines connect acme/app --cron '0 3 * * *'
```

---
Source: https://docs.kosa8.com/reference/ci-connect/
