Skip to content

Commit

Permalink
docs: add docs on mutation annotations (#2999)
Browse files Browse the repository at this point in the history
Signed-off-by: Xander Grzywinski <[email protected]>
Co-authored-by: Rita Zhang <[email protected]>
  • Loading branch information
salaxander and ritazh authored Sep 14, 2023
1 parent 83ca660 commit 2ed7d79
Show file tree
Hide file tree
Showing 16 changed files with 51 additions and 0 deletions.
2 changes: 2 additions & 0 deletions website/docs/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
5 changes: 5 additions & 0 deletions website/docs/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ must start with `:` or `@`. Also, if `assignPath` is set to a value which could
be interpreted as a domain, such as `my.repo.lib/app`, then `assignDomain` must
also be specified.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

### Adding an annotation
Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.10.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
4 changes: 4 additions & 0 deletions website/versioned_docs/version-v3.10.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,10 @@ spec:
- `spec.parameters.values.fromList` holds the list of values that will be added or removed.
- `operation` can be `merge` to insert values into the list if missing, or `prune` to remove values from the list. `merge` is default.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.11.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
4 changes: 4 additions & 0 deletions website/versioned_docs/version-v3.11.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,10 @@ spec:
- `spec.parameters.values.fromList` holds the list of values that will be added or removed.
- `operation` can be `merge` to insert values into the list if missing, or `prune` to remove values from the list. `merge` is default.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.12.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
5 changes: 5 additions & 0 deletions website/versioned_docs/version-v3.12.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ must start with `:` or `@`. Also, if `assignPath` is set to a value which could
be interpreted as a domain, such as `my.repo.lib/app`, then `assignDomain` must
also be specified.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

### Adding an annotation
Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.13.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
5 changes: 5 additions & 0 deletions website/versioned_docs/version-v3.13.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ must start with `:` or `@`. Also, if `assignPath` is set to a value which could
be interpreted as a domain, such as `my.repo.lib/app`, then `assignDomain` must
also be specified.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

### Adding an annotation
Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.7.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,5 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
4 changes: 4 additions & 0 deletions website/versioned_docs/version-v3.7.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,10 @@ spec:
- `spec.parameters.values.fromList` holds the list of values that will be added or removed.
- `operation` can be `merge` to insert values into the list if missing, or `prune` to remove values from the list. `merge` is default.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.8.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
4 changes: 4 additions & 0 deletions website/versioned_docs/version-v3.8.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,10 @@ spec:
- `spec.parameters.values.fromList` holds the list of values that will be added or removed.
- `operation` can be `merge` to insert values into the list if missing, or `prune` to remove values from the list. `merge` is default.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

Expand Down
2 changes: 2 additions & 0 deletions website/versioned_docs/version-v3.9.x/customize-startup.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ The `--mutation-annotations` flag adds the following two annotations to mutated
| `gatekeeper.sh/mutation-id` | The UUID of the mutation. |
| `gatekeeper.sh/mutations` | A list of comma-separated mutations in the format of `<MutationType>/<MutationNamespace>/<MutationName>:<MutationGeneration>` that are applied to the object. |

> ❗ Note that this will break the idempotence requirement that Kubernetes sets for mutation webhooks. See the [Kubernetes docs here](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#idempotence) for more details
## Other Configuration Options

For the complete list of configuration flags for your specific version of Gatekeeper, run the Gatekeeper binary with the `--help` flag. For example:
Expand Down
4 changes: 4 additions & 0 deletions website/versioned_docs/version-v3.9.x/mutation.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,10 @@ spec:
- `spec.parameters.values.fromList` holds the list of values that will be added or removed.
- `operation` can be `merge` to insert values into the list if missing, or `prune` to remove values from the list. `merge` is default.

### Mutation Annotations

You can have two recording annotations applied at mutation time by enabling the `--mutation-annotations` flag. More details can be found on the
[customize startup docs page](./customize-startup.md).

## Examples

Expand Down

0 comments on commit 2ed7d79

Please sign in to comment.