1. Packages
  2. Ibm Provider
  3. API Docs
  4. getPiNetworkPeers
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.getPiNetworkPeers

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Provides a read-only data source to retrieve information about pi_network_peers for on-prem locations.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const piNetworkPeers = ibm.getPiNetworkPeers({
        piCloudInstanceId: "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    pi_network_peers = ibm.get_pi_network_peers(pi_cloud_instance_id="49fba6c9-23f8-40bc-9899-aca322ee7d5b")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.GetPiNetworkPeers(ctx, &ibm.GetPiNetworkPeersArgs{
    			PiCloudInstanceId: "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var piNetworkPeers = Ibm.GetPiNetworkPeers.Invoke(new()
        {
            PiCloudInstanceId = "49fba6c9-23f8-40bc-9899-aca322ee7d5b",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IbmFunctions;
    import com.pulumi.ibm.inputs.GetPiNetworkPeersArgs;
    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 piNetworkPeers = IbmFunctions.getPiNetworkPeers(GetPiNetworkPeersArgs.builder()
                .piCloudInstanceId("49fba6c9-23f8-40bc-9899-aca322ee7d5b")
                .build());
    
        }
    }
    
    variables:
      piNetworkPeers:
        fn::invoke:
          function: ibm:getPiNetworkPeers
          arguments:
            piCloudInstanceId: 49fba6c9-23f8-40bc-9899-aca322ee7d5b
    

    Notes

    • Please find supported Regions for endpoints.
    • If a Power cloud instance is provisioned at lon04, The provider level attributes should be as follows:
      • region - lon
      • zone - lon04

    Example usage:

    import * as pulumi from "@pulumi/pulumi";
    
    import pulumi
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    
    return await Deployment.RunAsync(() => 
    {
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    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) {
        }
    }
    
    {}
    

    Using getPiNetworkPeers

    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 getPiNetworkPeers(args: GetPiNetworkPeersArgs, opts?: InvokeOptions): Promise<GetPiNetworkPeersResult>
    function getPiNetworkPeersOutput(args: GetPiNetworkPeersOutputArgs, opts?: InvokeOptions): Output<GetPiNetworkPeersResult>
    def get_pi_network_peers(id: Optional[str] = None,
                             pi_cloud_instance_id: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetPiNetworkPeersResult
    def get_pi_network_peers_output(id: Optional[pulumi.Input[str]] = None,
                             pi_cloud_instance_id: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetPiNetworkPeersResult]
    func GetPiNetworkPeers(ctx *Context, args *GetPiNetworkPeersArgs, opts ...InvokeOption) (*GetPiNetworkPeersResult, error)
    func GetPiNetworkPeersOutput(ctx *Context, args *GetPiNetworkPeersOutputArgs, opts ...InvokeOption) GetPiNetworkPeersResultOutput

    > Note: This function is named GetPiNetworkPeers in the Go SDK.

    public static class GetPiNetworkPeers 
    {
        public static Task<GetPiNetworkPeersResult> InvokeAsync(GetPiNetworkPeersArgs args, InvokeOptions? opts = null)
        public static Output<GetPiNetworkPeersResult> Invoke(GetPiNetworkPeersInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetPiNetworkPeersResult> getPiNetworkPeers(GetPiNetworkPeersArgs args, InvokeOptions options)
    public static Output<GetPiNetworkPeersResult> getPiNetworkPeers(GetPiNetworkPeersArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getPiNetworkPeers:getPiNetworkPeers
      arguments:
        # arguments dictionary

    The following arguments are supported:

    PiCloudInstanceId string
    The GUID of the service instance associated with an account.
    Id string
    (String) ID of the network peer.
    PiCloudInstanceId string
    The GUID of the service instance associated with an account.
    Id string
    (String) ID of the network peer.
    piCloudInstanceId String
    The GUID of the service instance associated with an account.
    id String
    (String) ID of the network peer.
    piCloudInstanceId string
    The GUID of the service instance associated with an account.
    id string
    (String) ID of the network peer.
    pi_cloud_instance_id str
    The GUID of the service instance associated with an account.
    id str
    (String) ID of the network peer.
    piCloudInstanceId String
    The GUID of the service instance associated with an account.
    id String
    (String) ID of the network peer.

    getPiNetworkPeers Result

    The following output properties are available:

    Id string
    (String) ID of the network peer.
    NetworkPeers List<GetPiNetworkPeersNetworkPeer>
    (List) List of network peers.
    PiCloudInstanceId string
    Id string
    (String) ID of the network peer.
    NetworkPeers []GetPiNetworkPeersNetworkPeer
    (List) List of network peers.
    PiCloudInstanceId string
    id String
    (String) ID of the network peer.
    networkPeers List<GetPiNetworkPeersNetworkPeer>
    (List) List of network peers.
    piCloudInstanceId String
    id string
    (String) ID of the network peer.
    networkPeers GetPiNetworkPeersNetworkPeer[]
    (List) List of network peers.
    piCloudInstanceId string
    id str
    (String) ID of the network peer.
    network_peers Sequence[GetPiNetworkPeersNetworkPeer]
    (List) List of network peers.
    pi_cloud_instance_id str
    id String
    (String) ID of the network peer.
    networkPeers List<Property Map>
    (List) List of network peers.
    piCloudInstanceId String

    Supporting Types

    GetPiNetworkPeersNetworkPeer

    Description string
    (String) Description of the network peer.
    Id string
    (String) ID of the network peer.
    Name string
    (String) Name of the network peer.
    Type string
    (String) Type of the network peer.
    Description string
    (String) Description of the network peer.
    Id string
    (String) ID of the network peer.
    Name string
    (String) Name of the network peer.
    Type string
    (String) Type of the network peer.
    description String
    (String) Description of the network peer.
    id String
    (String) ID of the network peer.
    name String
    (String) Name of the network peer.
    type String
    (String) Type of the network peer.
    description string
    (String) Description of the network peer.
    id string
    (String) ID of the network peer.
    name string
    (String) Name of the network peer.
    type string
    (String) Type of the network peer.
    description str
    (String) Description of the network peer.
    id str
    (String) ID of the network peer.
    name str
    (String) Name of the network peer.
    type str
    (String) Type of the network peer.
    description String
    (String) Description of the network peer.
    id String
    (String) ID of the network peer.
    name String
    (String) Name of the network peer.
    type String
    (String) Type of the network peer.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud