Skip to content

Commit 2406e00

Browse files
authored
docs: warn about branch auto-deletion (#667)
* docs: warn about branch auto-deletion Signed-off-by: Michael Crenshaw <[email protected]> * fix typos Signed-off-by: Michael Crenshaw <[email protected]> * note in both places Signed-off-by: Michael Crenshaw <[email protected]> --------- Signed-off-by: Michael Crenshaw <[email protected]>
1 parent f483257 commit 2406e00

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

docs/getting-started.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ stringData:
8989
> [!NOTE]
9090
> This Secret will need to be installed to the same namespace that you plan on creating PromotionStrategy resources in.
9191
92-
We also need a GitRepository and ScmProvider, which is are custom resources that represents a git repository and a provider.
92+
We also need a GitRepository and ScmProvider, which are custom resources that represent a git repository and a provider.
9393
Here is an example of both resources:
9494
9595
```yaml
@@ -116,6 +116,12 @@ spec:
116116
name: <your-scmprovider-name>
117117
```
118118
119+
> [!IMPORTANT]
120+
> Make sure your staging branches (`environment/development-next`, `environment/staging-next`, etc.) are not auto-deleted
121+
> when PRs are merged. You can do this either by disabling auto-deletion of branches in the repository settings (in
122+
> Settings > Automatically delete head branches) or by adding a branch protection rule for a matching pattern such as
123+
> `environment/*-next` (`/` characters are separators in GitHub's glob implementation, so `*-next` will not work).
124+
119125
> [!NOTE]
120126
> The GitRepository and ScmProvider also need to be installed to the same namespace that you plan on creating PromotionStrategy
121127
> resources in, and it also needs to be in the same namespace of the secret it references.

docs/tutorial-argocd-apps.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,12 @@ kubectl apply -f https://github.com/argoproj-labs/gitops-promoter/releases/downl
7878

7979
Argo provides an example repository: [https://github.com/argoproj/argocd-example-apps](https://github.com/argoproj/argocd-example-apps). Fork it!
8080

81+
> [!IMPORTANT]
82+
> Make sure your staging branches (`environment/development-next`, `environment/staging-next`, etc.) are not auto-deleted
83+
> when PRs are merged. You can do this either by disabling auto-deletion of branches in the repository settings (in
84+
> Settings > Automatically delete head branches) or by adding a branch protection rule for a matching pattern such as
85+
> `environment/*-next` (`/` characters are separators in GitHub's glob implementation, so `*-next` will not work).
86+
8187
### Create a GitHub application
8288

8389
In your GitHub account, go to Settings > Developer settings > GitHub Apps.

0 commit comments

Comments
 (0)