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

improve resource documentation for STACKIT LoadBalancer Service #594

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
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
9 changes: 8 additions & 1 deletion docs/resources/loadbalancer.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ provider "openstack" {

### Configuring the supporting infrastructure

The example below uses OpenStack to create the network, router, a public IP address and a compute instance.
The example below uses OpenStack to create the network, router, a public IP address and a compute instance.
The STACKIT Loadbalancer Service automatically adjust necessary Security Groups to its targets,
to avoid unnecessary changes in the terraform plan utilising the lifecycle function of terraform can be used.

## Example Usage

Expand Down Expand Up @@ -116,6 +118,11 @@ resource "openstack_compute_instance_v2" "example" {
network {
name = openstack_networking_network_v2.example.name
}

lifecycle {
# Security groups are modified by the STACKIT LoadBalancer Service, so terraform should ignore changes here
ignore_changes = [security_groups]
}
}

# Create a router and attach it to the public network
Expand Down
5 changes: 5 additions & 0 deletions examples/resources/stackit_loadbalancer/resource.tf
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ resource "openstack_compute_instance_v2" "example" {
network {
name = openstack_networking_network_v2.example.name
}

lifecycle {
# Security groups are modified by the STACKIT LoadBalancer Service, so terraform should ignore changes here
ignore_changes = [security_groups]
}
}

# Create a router and attach it to the public network
Expand Down