diff --git a/docs/gitrepo-add.md b/docs/gitrepo-add.md index c5929f657..73192e2a9 100644 --- a/docs/gitrepo-add.md +++ b/docs/gitrepo-add.md @@ -40,6 +40,25 @@ Put your private key into secret, use the namespace the GitRepo is in: kubectl create secret generic ssh-key -n fleet-default --from-file=ssh-privatekey=/file/to/private/key --type=kubernetes.io/ssh-auth ``` +Now the `clientSecretName` must be specified in the repo definition: + +```text +apiVersion: fleet.cattle.io/v1alpha1 +kind: GitRepo +metadata: + name: sample-ssh + # This namespace is special and auto-wired to deploy to the local cluster + namespace: fleet-local +spec: + # Everything from this repo will be run in this cluster. You trust me right? + repo: "git@github.com:rancher/fleet-examples" + # or + # repo: "ssh://git@github.com/rancher/fleet-examples" + clientSecretName: ssh-key + paths: + - simple +``` + :::caution Private key with passphrase is not supported.