1. Packages
  2. Cloudfoundry Provider
  3. API Docs
  4. getRoute
cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community

cloudfoundry.getRoute

Explore with Pulumi AI

cloudfoundry logo
cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community

    Gets information on a Cloud Foundry route.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as cloudfoundry from "@pulumi/cloudfoundry";
    
    const my_route = cloudfoundry.getRoute({
        domain: "domain-id",
        hostname: "my-host",
    });
    
    import pulumi
    import pulumi_cloudfoundry as cloudfoundry
    
    my_route = cloudfoundry.get_route(domain="domain-id",
        hostname="my-host")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/cloudfoundry/cloudfoundry"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudfoundry.LookupRoute(ctx, &cloudfoundry.LookupRouteArgs{
    			Domain:   "domain-id",
    			Hostname: pulumi.StringRef("my-host"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Cloudfoundry = Pulumi.Cloudfoundry;
    
    return await Deployment.RunAsync(() => 
    {
        var my_route = Cloudfoundry.GetRoute.Invoke(new()
        {
            Domain = "domain-id",
            Hostname = "my-host",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudfoundry.CloudfoundryFunctions;
    import com.pulumi.cloudfoundry.inputs.GetRouteArgs;
    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 my-route = CloudfoundryFunctions.getRoute(GetRouteArgs.builder()
                .domain("domain-id")
                .hostname("my-host")
                .build());
    
        }
    }
    
    variables:
      my-route:
        fn::invoke:
          function: cloudfoundry:getRoute
          arguments:
            domain: domain-id
            hostname: my-host
    

    Using getRoute

    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 getRoute(args: GetRouteArgs, opts?: InvokeOptions): Promise<GetRouteResult>
    function getRouteOutput(args: GetRouteOutputArgs, opts?: InvokeOptions): Output<GetRouteResult>
    def get_route(domain: Optional[str] = None,
                  hostname: Optional[str] = None,
                  id: Optional[str] = None,
                  org: Optional[str] = None,
                  path: Optional[str] = None,
                  port: Optional[float] = None,
                  opts: Optional[InvokeOptions] = None) -> GetRouteResult
    def get_route_output(domain: Optional[pulumi.Input[str]] = None,
                  hostname: Optional[pulumi.Input[str]] = None,
                  id: Optional[pulumi.Input[str]] = None,
                  org: Optional[pulumi.Input[str]] = None,
                  path: Optional[pulumi.Input[str]] = None,
                  port: Optional[pulumi.Input[float]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetRouteResult]
    func LookupRoute(ctx *Context, args *LookupRouteArgs, opts ...InvokeOption) (*LookupRouteResult, error)
    func LookupRouteOutput(ctx *Context, args *LookupRouteOutputArgs, opts ...InvokeOption) LookupRouteResultOutput

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

    public static class GetRoute 
    {
        public static Task<GetRouteResult> InvokeAsync(GetRouteArgs args, InvokeOptions? opts = null)
        public static Output<GetRouteResult> Invoke(GetRouteInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetRouteResult> getRoute(GetRouteArgs args, InvokeOptions options)
    public static Output<GetRouteResult> getRoute(GetRouteArgs args, InvokeOptions options)
    
    fn::invoke:
      function: cloudfoundry:index/getRoute:getRoute
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Domain string
    The domain guid associated to the route.
    Hostname string
    The hostname associated to the route to lookup.
    Id string
    The GUID of the route.
    Org string
    The org guid associated to the route to lookup.
    Path string
    The path associated to the route to lookup.
    Port double
    The port associated to the route to lookup.
    Domain string
    The domain guid associated to the route.
    Hostname string
    The hostname associated to the route to lookup.
    Id string
    The GUID of the route.
    Org string
    The org guid associated to the route to lookup.
    Path string
    The path associated to the route to lookup.
    Port float64
    The port associated to the route to lookup.
    domain String
    The domain guid associated to the route.
    hostname String
    The hostname associated to the route to lookup.
    id String
    The GUID of the route.
    org String
    The org guid associated to the route to lookup.
    path String
    The path associated to the route to lookup.
    port Double
    The port associated to the route to lookup.
    domain string
    The domain guid associated to the route.
    hostname string
    The hostname associated to the route to lookup.
    id string
    The GUID of the route.
    org string
    The org guid associated to the route to lookup.
    path string
    The path associated to the route to lookup.
    port number
    The port associated to the route to lookup.
    domain str
    The domain guid associated to the route.
    hostname str
    The hostname associated to the route to lookup.
    id str
    The GUID of the route.
    org str
    The org guid associated to the route to lookup.
    path str
    The path associated to the route to lookup.
    port float
    The port associated to the route to lookup.
    domain String
    The domain guid associated to the route.
    hostname String
    The hostname associated to the route to lookup.
    id String
    The GUID of the route.
    org String
    The org guid associated to the route to lookup.
    path String
    The path associated to the route to lookup.
    port Number
    The port associated to the route to lookup.

    getRoute Result

    The following output properties are available:

    Domain string
    Hostname string
    (Optional) The hostname associated to the route.
    Id string
    The GUID of the route.
    Path string
    (Optional) The path associated to the route.
    Port double
    (Optional) The port associated to the route.
    Org string
    Domain string
    Hostname string
    (Optional) The hostname associated to the route.
    Id string
    The GUID of the route.
    Path string
    (Optional) The path associated to the route.
    Port float64
    (Optional) The port associated to the route.
    Org string
    domain String
    hostname String
    (Optional) The hostname associated to the route.
    id String
    The GUID of the route.
    path String
    (Optional) The path associated to the route.
    port Double
    (Optional) The port associated to the route.
    org String
    domain string
    hostname string
    (Optional) The hostname associated to the route.
    id string
    The GUID of the route.
    path string
    (Optional) The path associated to the route.
    port number
    (Optional) The port associated to the route.
    org string
    domain str
    hostname str
    (Optional) The hostname associated to the route.
    id str
    The GUID of the route.
    path str
    (Optional) The path associated to the route.
    port float
    (Optional) The port associated to the route.
    org str
    domain String
    hostname String
    (Optional) The hostname associated to the route.
    id String
    The GUID of the route.
    path String
    (Optional) The path associated to the route.
    port Number
    (Optional) The port associated to the route.
    org String

    Package Details

    Repository
    cloudfoundry cloudfoundry-community/terraform-provider-cloudfoundry
    License
    Notes
    This Pulumi package is based on the cloudfoundry Terraform Provider.
    cloudfoundry logo
    cloudfoundry 0.54.0 published on Monday, Apr 14, 2025 by cloudfoundry-community