Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi
oci.RecoveryMod.getRecoveryServiceSubnets
Explore with Pulumi AI
This data source provides the list of Recovery Service Subnets in Oracle Cloud Infrastructure Recovery service.
Returns a list of Recovery Service Subnets.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testRecoveryServiceSubnets = oci.RecoveryMod.getRecoveryServiceSubnets({
compartmentId: compartmentId,
displayName: recoveryServiceSubnetDisplayName,
id: recoveryServiceSubnetId,
state: recoveryServiceSubnetState,
vcnId: testVcn.id,
});
import pulumi
import pulumi_oci as oci
test_recovery_service_subnets = oci.RecoveryMod.get_recovery_service_subnets(compartment_id=compartment_id,
display_name=recovery_service_subnet_display_name,
id=recovery_service_subnet_id,
state=recovery_service_subnet_state,
vcn_id=test_vcn["id"])
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/RecoveryMod"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := RecoveryMod.GetRecoveryServiceSubnets(ctx, &recoverymod.GetRecoveryServiceSubnetsArgs{
CompartmentId: compartmentId,
DisplayName: pulumi.StringRef(recoveryServiceSubnetDisplayName),
Id: pulumi.StringRef(recoveryServiceSubnetId),
State: pulumi.StringRef(recoveryServiceSubnetState),
VcnId: pulumi.StringRef(testVcn.Id),
}, 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 testRecoveryServiceSubnets = Oci.RecoveryMod.GetRecoveryServiceSubnets.Invoke(new()
{
CompartmentId = compartmentId,
DisplayName = recoveryServiceSubnetDisplayName,
Id = recoveryServiceSubnetId,
State = recoveryServiceSubnetState,
VcnId = testVcn.Id,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.RecoveryMod.RecoveryModFunctions;
import com.pulumi.oci.RecoveryMod.inputs.GetRecoveryServiceSubnetsArgs;
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 testRecoveryServiceSubnets = RecoveryModFunctions.getRecoveryServiceSubnets(GetRecoveryServiceSubnetsArgs.builder()
.compartmentId(compartmentId)
.displayName(recoveryServiceSubnetDisplayName)
.id(recoveryServiceSubnetId)
.state(recoveryServiceSubnetState)
.vcnId(testVcn.id())
.build());
}
}
variables:
testRecoveryServiceSubnets:
fn::invoke:
Function: oci:RecoveryMod:getRecoveryServiceSubnets
Arguments:
compartmentId: ${compartmentId}
displayName: ${recoveryServiceSubnetDisplayName}
id: ${recoveryServiceSubnetId}
state: ${recoveryServiceSubnetState}
vcnId: ${testVcn.id}
Using getRecoveryServiceSubnets
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 getRecoveryServiceSubnets(args: GetRecoveryServiceSubnetsArgs, opts?: InvokeOptions): Promise<GetRecoveryServiceSubnetsResult>
function getRecoveryServiceSubnetsOutput(args: GetRecoveryServiceSubnetsOutputArgs, opts?: InvokeOptions): Output<GetRecoveryServiceSubnetsResult>
def get_recovery_service_subnets(compartment_id: Optional[str] = None,
display_name: Optional[str] = None,
filters: Optional[Sequence[_recoverymod.GetRecoveryServiceSubnetsFilter]] = None,
id: Optional[str] = None,
state: Optional[str] = None,
vcn_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetRecoveryServiceSubnetsResult
def get_recovery_service_subnets_output(compartment_id: Optional[pulumi.Input[str]] = None,
display_name: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[_recoverymod.GetRecoveryServiceSubnetsFilterArgs]]]] = None,
id: Optional[pulumi.Input[str]] = None,
state: Optional[pulumi.Input[str]] = None,
vcn_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetRecoveryServiceSubnetsResult]
func GetRecoveryServiceSubnets(ctx *Context, args *GetRecoveryServiceSubnetsArgs, opts ...InvokeOption) (*GetRecoveryServiceSubnetsResult, error)
func GetRecoveryServiceSubnetsOutput(ctx *Context, args *GetRecoveryServiceSubnetsOutputArgs, opts ...InvokeOption) GetRecoveryServiceSubnetsResultOutput
> Note: This function is named GetRecoveryServiceSubnets
in the Go SDK.
public static class GetRecoveryServiceSubnets
{
public static Task<GetRecoveryServiceSubnetsResult> InvokeAsync(GetRecoveryServiceSubnetsArgs args, InvokeOptions? opts = null)
public static Output<GetRecoveryServiceSubnetsResult> Invoke(GetRecoveryServiceSubnetsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetRecoveryServiceSubnetsResult> getRecoveryServiceSubnets(GetRecoveryServiceSubnetsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:RecoveryMod/getRecoveryServiceSubnets:getRecoveryServiceSubnets
arguments:
# arguments dictionary
The following arguments are supported:
- Compartment
Id string - The compartment OCID.
- Display
Name string - A filter to return only resources that match the entire 'displayname' given.
- Filters
List<Get
Recovery Service Subnets Filter> - Id string
- The recovery service subnet OCID.
- State string
- A filter to return only the resources that match the specified lifecycle state.
- Vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- Compartment
Id string - The compartment OCID.
- Display
Name string - A filter to return only resources that match the entire 'displayname' given.
- Filters
[]Get
Recovery Service Subnets Filter - Id string
- The recovery service subnet OCID.
- State string
- A filter to return only the resources that match the specified lifecycle state.
- Vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id String - The compartment OCID.
- display
Name String - A filter to return only resources that match the entire 'displayname' given.
- filters
List<Get
Recovery Service Subnets Filter> - id String
- The recovery service subnet OCID.
- state String
- A filter to return only the resources that match the specified lifecycle state.
- vcn
Id String - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id string - The compartment OCID.
- display
Name string - A filter to return only resources that match the entire 'displayname' given.
- filters
Get
Recovery Service Subnets Filter[] - id string
- The recovery service subnet OCID.
- state string
- A filter to return only the resources that match the specified lifecycle state.
- vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment_
id str - The compartment OCID.
- display_
name str - A filter to return only resources that match the entire 'displayname' given.
- filters
Sequence[recoverymod.
Get Recovery Service Subnets Filter] - id str
- The recovery service subnet OCID.
- state str
- A filter to return only the resources that match the specified lifecycle state.
- vcn_
id str - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id String - The compartment OCID.
- display
Name String - A filter to return only resources that match the entire 'displayname' given.
- filters List<Property Map>
- id String
- The recovery service subnet OCID.
- state String
- A filter to return only the resources that match the specified lifecycle state.
- vcn
Id String - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
getRecoveryServiceSubnets Result
The following output properties are available:
- Compartment
Id string - The compartment OCID.
- Recovery
Service List<GetSubnet Collections Recovery Service Subnets Recovery Service Subnet Collection> - The list of recovery_service_subnet_collection.
- Display
Name string - A user-provided name for the recovery service subnet.
- Filters
List<Get
Recovery Service Subnets Filter> - Id string
- The recovery service subnet OCID.
- State string
- The current state of the recovery service subnet.
- Vcn
Id string - VCN Identifier.
- Compartment
Id string - The compartment OCID.
- Recovery
Service []GetSubnet Collections Recovery Service Subnets Recovery Service Subnet Collection - The list of recovery_service_subnet_collection.
- Display
Name string - A user-provided name for the recovery service subnet.
- Filters
[]Get
Recovery Service Subnets Filter - Id string
- The recovery service subnet OCID.
- State string
- The current state of the recovery service subnet.
- Vcn
Id string - VCN Identifier.
- compartment
Id String - The compartment OCID.
- recovery
Service List<GetSubnet Collections Recovery Service Subnets Recovery Service Subnet Collection> - The list of recovery_service_subnet_collection.
- display
Name String - A user-provided name for the recovery service subnet.
- filters
List<Get
Recovery Service Subnets Filter> - id String
- The recovery service subnet OCID.
- state String
- The current state of the recovery service subnet.
- vcn
Id String - VCN Identifier.
- compartment
Id string - The compartment OCID.
- recovery
Service GetSubnet Collections Recovery Service Subnets Recovery Service Subnet Collection[] - The list of recovery_service_subnet_collection.
- display
Name string - A user-provided name for the recovery service subnet.
- filters
Get
Recovery Service Subnets Filter[] - id string
- The recovery service subnet OCID.
- state string
- The current state of the recovery service subnet.
- vcn
Id string - VCN Identifier.
- compartment_
id str - The compartment OCID.
- recovery_
service_ Sequence[recoverymod.subnet_ collections Get Recovery Service Subnets Recovery Service Subnet Collection] - The list of recovery_service_subnet_collection.
- display_
name str - A user-provided name for the recovery service subnet.
- filters
Sequence[recoverymod.
Get Recovery Service Subnets Filter] - id str
- The recovery service subnet OCID.
- state str
- The current state of the recovery service subnet.
- vcn_
id str - VCN Identifier.
- compartment
Id String - The compartment OCID.
- recovery
Service List<Property Map>Subnet Collections - The list of recovery_service_subnet_collection.
- display
Name String - A user-provided name for the recovery service subnet.
- filters List<Property Map>
- id String
- The recovery service subnet OCID.
- state String
- The current state of the recovery service subnet.
- vcn
Id String - VCN Identifier.
Supporting Types
GetRecoveryServiceSubnetsFilter
GetRecoveryServiceSubnetsRecoveryServiceSubnetCollection
GetRecoveryServiceSubnetsRecoveryServiceSubnetCollectionItem
- Compartment
Id string - The compartment OCID.
- Dictionary<string, string>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - Display
Name string - A filter to return only resources that match the entire 'displayname' given.
- Dictionary<string, string>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- Id string
- The recovery service subnet OCID.
- Lifecycle
Details string - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- Nsg
Ids List<string> - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- State string
- A filter to return only the resources that match the specified lifecycle state.
- Subnet
Id string - Deprecated. One of the subnets associated with the Recovery Service subnet.
- Subnets List<string>
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- Dictionary<string, string>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - Time
Created string - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- Time
Updated string - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- Vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- Compartment
Id string - The compartment OCID.
- map[string]string
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - Display
Name string - A filter to return only resources that match the entire 'displayname' given.
- map[string]string
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- Id string
- The recovery service subnet OCID.
- Lifecycle
Details string - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- Nsg
Ids []string - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- State string
- A filter to return only the resources that match the specified lifecycle state.
- Subnet
Id string - Deprecated. One of the subnets associated with the Recovery Service subnet.
- Subnets []string
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- map[string]string
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - Time
Created string - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- Time
Updated string - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- Vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id String - The compartment OCID.
- Map<String,String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - display
Name String - A filter to return only resources that match the entire 'displayname' given.
- Map<String,String>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id String
- The recovery service subnet OCID.
- lifecycle
Details String - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- nsg
Ids List<String> - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- state String
- A filter to return only the resources that match the specified lifecycle state.
- subnet
Id String - Deprecated. One of the subnets associated with the Recovery Service subnet.
- subnets List<String>
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- Map<String,String>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - time
Created String - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- time
Updated String - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- vcn
Id String - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id string - The compartment OCID.
- {[key: string]: string}
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - display
Name string - A filter to return only resources that match the entire 'displayname' given.
- {[key: string]: string}
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id string
- The recovery service subnet OCID.
- lifecycle
Details string - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- nsg
Ids string[] - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- state string
- A filter to return only the resources that match the specified lifecycle state.
- subnet
Id string - Deprecated. One of the subnets associated with the Recovery Service subnet.
- subnets string[]
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- {[key: string]: string}
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - time
Created string - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- time
Updated string - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- vcn
Id string - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment_
id str - The compartment OCID.
- Mapping[str, str]
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - display_
name str - A filter to return only resources that match the entire 'displayname' given.
- Mapping[str, str]
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id str
- The recovery service subnet OCID.
- lifecycle_
details str - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- nsg_
ids Sequence[str] - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- state str
- A filter to return only the resources that match the specified lifecycle state.
- subnet_
id str - Deprecated. One of the subnets associated with the Recovery Service subnet.
- subnets Sequence[str]
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- Mapping[str, str]
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - time_
created str - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- time_
updated str - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- vcn_
id str - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
- compartment
Id String - The compartment OCID.
- Map<String>
- Defined tags for this resource. Each key is predefined and scoped to a namespace. Example:
{"foo-namespace.bar-key": "value"}
. For more information, see Resource Tags - display
Name String - A filter to return only resources that match the entire 'displayname' given.
- Map<String>
- Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example:
{"bar-key": "value"}
- id String
- The recovery service subnet OCID.
- lifecycle
Details String - Detailed description about the current lifecycle state of the recovery service subnet. For example, it can be used to provide actionable information for a resource in a Failed state
- nsg
Ids List<String> - A list of network security group (NSG) OCIDs that are associated with the Recovery Service subnet. You can specify a maximum of 5 unique OCIDs, which implies that you can associate a maximum of 5 NSGs to each Recovery Service subnet. Specify an empty array if you want to remove all the associated NSGs from a Recovery Service subnet. See Network Security Groups for more information.
- state String
- A filter to return only the resources that match the specified lifecycle state.
- subnet
Id String - Deprecated. One of the subnets associated with the Recovery Service subnet.
- subnets List<String>
- A list of OCIDs of all the subnets associated with the Recovery Service subnet.
- Map<String>
- Usage of system tag keys. These predefined keys are scoped to namespaces. Example:
{"orcl-cloud.free-tier-retained": "true"}
. For more information, see Resource Tags - time
Created String - An RFC3339 formatted datetime string that indicates the last created time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- time
Updated String - An RFC3339 formatted datetime string that indicates the last updated time for a recovery service subnet. For example: '2020-05-22T21:10:29.600Z'.
- vcn
Id String - The OCID of the virtual cloud network (VCN) associated with the recovery service subnet.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.