# Deploy from GitHub

> Learn how repository scopes, auto-deploy configurations, and push webhooks operate.

- **Category**: Deploy & Configure
- **Last Verified**: 2026-07-14

Deploying source repositories involves linking your GitHub user or organization to Kubeletto. Once configured, Kubeletto registers webhook routes to listen to git commits.

## How Auto-Deploy works

- Kubeletto listens for GitHub `push` webhook payloads.
- When a push event matches your configured deployment branch (e.g. `main`), it triggers an asynchronous build queue event.
- A worker clones the branch at the current commit SHA and initiates compilation.

## Manual Redeploy

To trigger a fresh build without forcing a new git commit, run the redeploy trigger:

```bash
kubeletto deploy my-service --repo git@github.com:your-user/your-repo.git --branch main
```

## Cancelling a Deployment

If you want to abort a running build, capture the deployment ID from `status` and cancel it:

```bash
kubeletto status my-service
# Find deployment ID (e.g. dep_abc123)
# Curl API route or cancel command if supported:
# To cancel, terminate via CLI abort or command.
```

