Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README with new wait_for condition information #175

Merged
merged 1 commit into from
Oct 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 19 additions & 3 deletions docs/resources/kubectl_manifest.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ YAML

### With explicit `wait_for`

If `wait_for` is specified, upon applying the resource, provider will wait for **all** conditions to become true before proceeding further.
If `wait_for` is specified, upon applying the resource, provider will wait for **all** conditions to become true before proceeding further.

```hcl
resource "kubectl_manifest" "test" {
Expand All @@ -56,6 +56,14 @@ resource "kubectl_manifest" "test" {
value = "^(\\d+(\\.|$)){4}"
value_type = "regex"
}
condition {
type = "ContainersReady"
status = "True"
}
condition {
type = "Ready"
status = "True"
}
}
yaml_body = <<YAML
apiVersion: v1
Expand Down Expand Up @@ -94,9 +102,10 @@ YAML

### `wait_for`

Required:
Required, at least one of:

* `field` (Block List, Min: 1) Condition criteria for a field (see [below for nested schema](#wait_forfield))
* `field` (Block List, Min: 0) Condition criteria for a field (see [below for nested schema](#wait_forfield))
* `condition` (Block List, Min: 0) Condition criteria for a condition (see [below for nested schema](#wait_forcondition))

### `wait_for.field`

Expand All @@ -109,6 +118,13 @@ Optional:

- `value_type` (String) Value type. Can be either a `eq` (equivalent) or `regex`

### `wait_for.condition`

Required:

* `type` (String) Type as expected from the resulting Condition object
* `status` (String) Status to wait for in the resulting Condition object

## Attribute Reference

* `yaml_body_parsed` - Obfuscated version of `yaml_body`, with `sensitive_fields` hidden.
Expand Down
Loading