Skip to content

Commit

Permalink
Update is_lb_listener.html.markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
uibm committed Oct 26, 2021
1 parent 60df2b2 commit 422652b
Showing 1 changed file with 31 additions and 1 deletion.
32 changes: 31 additions & 1 deletion website/docs/r/is_lb_listener.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ resource "ibm_is_lb_listener" "lb_listener1"{
lb = ibm_is_lb.lb2.id
port = "9086"
protocol = "https"
certificate_instance="crn:v1:staging:public:cloudcerts:us-south:a2d1bace7b46e4815a81e52c6ffeba5cf:af925157-b125-4db2-b642-adacb8b9c7f5:certificate:c81627a1bf6f766379cc4b98fd2a44ed"
certificate_instance="crn:v1:bluemix:public:cloudcerts:us-south:a2d1bace7b46e4815a81e52c6ffeba5cf:af925157-b125-4db2-b642-adacb8b9c7f5:certificate:c81627a1bf6f766379cc4b98fd2a44ed"
}
resource "ibm_is_lb_listener" "lb_listener2"{
Expand All @@ -74,6 +74,35 @@ resource "ibm_is_lb_listener" "lb_listener2"{
}
```

### Sample to create a load balancer listener for a route mode enabled private network load balancer.

```terraform
resource "ibm_is_vpc" "vpc" {
name = "test-vpc"
}
resource "ibm_is_subnet" "subnet" {
name = "test-subnet"
vpc = "${ibm_is_vpc.vpc.id}"
zone = "us-south-2"
ipv4_cidr_block = "10.240.68.0/24"
}
resource "ibm_is_lb" "nlb" {
name = "test-nlb"
subnets = [ibm_is_subnet.subnet.id]
profile = "network-fixed"
type = "private"
route_mode = "true"
}
resource "ibm_is_lb_listener" "nlbHttpListener1" {
lb = ibm_is_lb.nlb.id
protocol = "tcp"
}
```

## Timeouts
The `ibm_is_lb_listener` resource provides the following [Timeouts](https://www.terraform.io/docs/language/resources/syntax.html) configuration options:

Expand All @@ -90,6 +119,7 @@ Review the argument references that you can specify for your resource.
- `port`- (Optional, Depreciated Integer) The listener port number. Valid range 1 to 65535.
**NOTE**:
- Private network load balancers with `route_mode` enabled don't support `port`, they support `port` range from `port_min`(1) - `port_max`(65535).
- Only accepted value of `port` for `route_mode` enabled private network load balancer is `1`. Any other value will show change/update-in-place and return an error.

- `protocol` - (Required, String) The listener protocol. Enumeration type are `http`, `tcp`, and `https`. Network load balancer supports only `tcp` protocol.
- `default_pool` - (Optional, String) The load balancer pool unique identifier.
Expand Down

0 comments on commit 422652b

Please sign in to comment.