Git Deploy
Basil can serve your site as a Git repository over HTTPS. Clone it, edit, git push β and the running server picks up the changes with no restart. Push-to-deploy with nothing but Git.
Basil-only. The Git endpoint is part of the Basil server.
Quick Start
1. Enable it in basil.yaml:
git:
enabled: true
require_auth: true
2. Create a user and API key (see Running Basil):
basil users create # role: editor or admin
basil apikey create # β bsk_abc123β¦ (save it!)
3. Clone your live site:
git clone https://anything:bsk_abc123...@yourserver.com/.git mysite
The username is ignored β only the API key matters.
4. Push changes:
cd mysite
# editβ¦
git add . && git commit -m "Update homepage"
git push
Basil reloads automatically on push.
Authentication & Roles
Git access uses API keys via HTTP Basic Auth (key as the password).
| Operation | Required role |
|---|---|
| Clone / pull | any authenticated user |
| Push | editor or admin |
Revoke a compromised key with basil apikey revoke <id> β no need to touch user accounts.
See Also
- Authentication β users, roles, and API keys
- Running Basil β the
usersandapikeyCLI - The Git guide β hooks, workflows, and troubleshooting