CLI:Canasta gitops init
canasta gitops init
Bootstrap a new gitops repository from an existing installation
Synopsis
Bootstrap git-based configuration management for a Canasta installation.
Sets up git, git-crypt, env.template, hosts.yaml, converts extensions/skins to submodules, and pushes to the remote. The remote repository must be empty (no commits). Use --force to overwrite a non-empty remote.
The git-crypt key is exported to the path specified by --key. Store this key securely — it is needed to unlock the repo on other servers.
Use --pull-requests to require changes to go through pull requests instead of pushing directly to main. This enables review workflows for multi-server deployments.
Use --repair to fix submodule registration in an existing gitops repository without re-initializing. This re-converts extensions/skins that were committed as regular directories instead of submodules.
To join an existing gitops repository instead, use "canasta gitops join".
canasta gitops init [flags]
Flags
| Flag | Shorthand | Description | Default | Required |
|---|---|---|---|---|
--force |
Force push to a non-empty remote repository | |||
--help |
-h |
help for init | ||
--key |
Path to export the git-crypt key | ✓ | ||
--name |
-n |
Name for this host in hosts.yaml | ✓ | |
--pull-requests |
Require pull requests instead of pushing directly to main | |||
--repair |
Re-register extensions/skins as proper submodules | |||
--repo |
Git repository URL | ✓ | ||
--role |
Host role: source, sink, or both | both |
||
--id |
-i |
Canasta instance ID | instance associated with current directory | |
--verbose |
-v |
Verbose output |