Oracle Cloud Infrastructure v2.33.0 published on Thursday, May 1, 2025 by Pulumi
oci.Core.getPublicIpPools
Explore with Pulumi AI
This data source provides the list of Public Ip Pools in Oracle Cloud Infrastructure Core service.
Lists the public IP pools in the specified compartment. You can filter the list using query parameters.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testPublicIpPools = oci.Core.getPublicIpPools({
    compartmentId: compartmentId,
    byoipRangeId: testByoipRange.id,
    displayName: publicIpPoolDisplayName,
});
import pulumi
import pulumi_oci as oci
test_public_ip_pools = oci.Core.get_public_ip_pools(compartment_id=compartment_id,
    byoip_range_id=test_byoip_range["id"],
    display_name=public_ip_pool_display_name)
package main
import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/core"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := core.GetPublicIpPools(ctx, &core.GetPublicIpPoolsArgs{
			CompartmentId: compartmentId,
			ByoipRangeId:  pulumi.StringRef(testByoipRange.Id),
			DisplayName:   pulumi.StringRef(publicIpPoolDisplayName),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() => 
{
    var testPublicIpPools = Oci.Core.GetPublicIpPools.Invoke(new()
    {
        CompartmentId = compartmentId,
        ByoipRangeId = testByoipRange.Id,
        DisplayName = publicIpPoolDisplayName,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Core.CoreFunctions;
import com.pulumi.oci.Core.inputs.GetPublicIpPoolsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }
    public static void stack(Context ctx) {
        final var testPublicIpPools = CoreFunctions.getPublicIpPools(GetPublicIpPoolsArgs.builder()
            .compartmentId(compartmentId)
            .byoipRangeId(testByoipRange.id())
            .displayName(publicIpPoolDisplayName)
            .build());
    }
}
variables:
  testPublicIpPools:
    fn::invoke:
      function: oci:Core:getPublicIpPools
      arguments:
        compartmentId: ${compartmentId}
        byoipRangeId: ${testByoipRange.id}
        displayName: ${publicIpPoolDisplayName}
Using getPublicIpPools
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getPublicIpPools(args: GetPublicIpPoolsArgs, opts?: InvokeOptions): Promise<GetPublicIpPoolsResult>
function getPublicIpPoolsOutput(args: GetPublicIpPoolsOutputArgs, opts?: InvokeOptions): Output<GetPublicIpPoolsResult>def get_public_ip_pools(byoip_range_id: Optional[str] = None,
                        compartment_id: Optional[str] = None,
                        display_name: Optional[str] = None,
                        filters: Optional[Sequence[GetPublicIpPoolsFilter]] = None,
                        opts: Optional[InvokeOptions] = None) -> GetPublicIpPoolsResult
def get_public_ip_pools_output(byoip_range_id: Optional[pulumi.Input[str]] = None,
                        compartment_id: Optional[pulumi.Input[str]] = None,
                        display_name: Optional[pulumi.Input[str]] = None,
                        filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetPublicIpPoolsFilterArgs]]]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetPublicIpPoolsResult]func GetPublicIpPools(ctx *Context, args *GetPublicIpPoolsArgs, opts ...InvokeOption) (*GetPublicIpPoolsResult, error)
func GetPublicIpPoolsOutput(ctx *Context, args *GetPublicIpPoolsOutputArgs, opts ...InvokeOption) GetPublicIpPoolsResultOutput> Note: This function is named GetPublicIpPools in the Go SDK.
public static class GetPublicIpPools 
{
    public static Task<GetPublicIpPoolsResult> InvokeAsync(GetPublicIpPoolsArgs args, InvokeOptions? opts = null)
    public static Output<GetPublicIpPoolsResult> Invoke(GetPublicIpPoolsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetPublicIpPoolsResult> getPublicIpPools(GetPublicIpPoolsArgs args, InvokeOptions options)
public static Output<GetPublicIpPoolsResult> getPublicIpPools(GetPublicIpPoolsArgs args, InvokeOptions options)
fn::invoke:
  function: oci:Core/getPublicIpPools:getPublicIpPools
  arguments:
    # arguments dictionaryThe following arguments are supported:
- CompartmentId string
- The OCID of the compartment.
- ByoipRange stringId 
- A filter to return only resources that match the given BYOIP CIDR block.
- DisplayName string
- A filter to return only resources that match the given display name exactly.
- Filters
List<GetPublic Ip Pools Filter> 
- CompartmentId string
- The OCID of the compartment.
- ByoipRange stringId 
- A filter to return only resources that match the given BYOIP CIDR block.
- DisplayName string
- A filter to return only resources that match the given display name exactly.
- Filters
[]GetPublic Ip Pools Filter 
- compartmentId String
- The OCID of the compartment.
- byoipRange StringId 
- A filter to return only resources that match the given BYOIP CIDR block.
- displayName String
- A filter to return only resources that match the given display name exactly.
- filters
List<GetPublic Ip Pools Filter> 
- compartmentId string
- The OCID of the compartment.
- byoipRange stringId 
- A filter to return only resources that match the given BYOIP CIDR block.
- displayName string
- A filter to return only resources that match the given display name exactly.
- filters
GetPublic Ip Pools Filter[] 
- compartment_id str
- The OCID of the compartment.
- byoip_range_ strid 
- A filter to return only resources that match the given BYOIP CIDR block.
- display_name str
- A filter to return only resources that match the given display name exactly.
- filters
Sequence[GetPublic Ip Pools Filter] 
- compartmentId String
- The OCID of the compartment.
- byoipRange StringId 
- A filter to return only resources that match the given BYOIP CIDR block.
- displayName String
- A filter to return only resources that match the given display name exactly.
- filters List<Property Map>
getPublicIpPools Result
The following output properties are available:
- CompartmentId string
- The OCID of the compartment containing this pool.
- Id string
- The provider-assigned unique ID for this managed resource.
- PublicIp List<GetPool Collections Public Ip Pools Public Ip Pool Collection> 
- The list of public_ip_pool_collection.
- ByoipRange stringId 
- DisplayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Filters
List<GetPublic Ip Pools Filter> 
- CompartmentId string
- The OCID of the compartment containing this pool.
- Id string
- The provider-assigned unique ID for this managed resource.
- PublicIp []GetPool Collections Public Ip Pools Public Ip Pool Collection 
- The list of public_ip_pool_collection.
- ByoipRange stringId 
- DisplayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- Filters
[]GetPublic Ip Pools Filter 
- compartmentId String
- The OCID of the compartment containing this pool.
- id String
- The provider-assigned unique ID for this managed resource.
- publicIp List<GetPool Collections Public Ip Pools Public Ip Pool Collection> 
- The list of public_ip_pool_collection.
- byoipRange StringId 
- displayName String
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- filters
List<GetPublic Ip Pools Filter> 
- compartmentId string
- The OCID of the compartment containing this pool.
- id string
- The provider-assigned unique ID for this managed resource.
- publicIp GetPool Collections Public Ip Pools Public Ip Pool Collection[] 
- The list of public_ip_pool_collection.
- byoipRange stringId 
- displayName string
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- filters
GetPublic Ip Pools Filter[] 
- compartment_id str
- The OCID of the compartment containing this pool.
- id str
- The provider-assigned unique ID for this managed resource.
- public_ip_ Sequence[Getpool_ collections Public Ip Pools Public Ip Pool Collection] 
- The list of public_ip_pool_collection.
- byoip_range_ strid 
- display_name str
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- filters
Sequence[GetPublic Ip Pools Filter] 
- compartmentId String
- The OCID of the compartment containing this pool.
- id String
- The provider-assigned unique ID for this managed resource.
- publicIp List<Property Map>Pool Collections 
- The list of public_ip_pool_collection.
- byoipRange StringId 
- displayName String
- A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
- filters List<Property Map>
Supporting Types
GetPublicIpPoolsFilter    
GetPublicIpPoolsPublicIpPoolCollection       
GetPublicIpPoolsPublicIpPoolCollectionItem        
- CidrBlocks List<string>
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- CompartmentId string
- The OCID of the compartment.
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DisplayName string
- A filter to return only resources that match the given display name exactly.
- Dictionary<string, string>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the public IP pool.
- State string
- The public IP pool's current state.
- TimeCreated string
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
- CidrBlocks []string
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- CompartmentId string
- The OCID of the compartment.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- DisplayName string
- A filter to return only resources that match the given display name exactly.
- map[string]string
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- Id string
- The OCID of the public IP pool.
- State string
- The public IP pool's current state.
- TimeCreated string
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
- cidrBlocks List<String>
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- compartmentId String
- The OCID of the compartment.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName String
- A filter to return only resources that match the given display name exactly.
- Map<String,String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the public IP pool.
- state String
- The public IP pool's current state.
- timeCreated String
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
- cidrBlocks string[]
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- compartmentId string
- The OCID of the compartment.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName string
- A filter to return only resources that match the given display name exactly.
- {[key: string]: string}
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id string
- The OCID of the public IP pool.
- state string
- The public IP pool's current state.
- timeCreated string
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
- cidr_blocks Sequence[str]
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- compartment_id str
- The OCID of the compartment.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- display_name str
- A filter to return only resources that match the given display name exactly.
- Mapping[str, str]
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id str
- The OCID of the public IP pool.
- state str
- The public IP pool's current state.
- time_created str
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
- cidrBlocks List<String>
- The CIDR blocks added to this pool. This could be all or a portion of a BYOIP CIDR block.
- compartmentId String
- The OCID of the compartment.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
- displayName String
- A filter to return only resources that match the given display name exactly.
- Map<String>
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
- id String
- The OCID of the public IP pool.
- state String
- The public IP pool's current state.
- timeCreated String
- The date and time the public IP pool was created, in the format defined by RFC3339. Example: 2016-08-25T21:10:29.600Z
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the ociTerraform Provider.