1. Packages
  2. Octopusdeploy Provider
  3. API Docs
  4. PollingSubscriptionId
octopusdeploy 0.43.1 published on Wednesday, Apr 30, 2025 by octopusdeploylabs

octopusdeploy.PollingSubscriptionId

Explore with Pulumi AI

octopusdeploy logo
octopusdeploy 0.43.1 published on Wednesday, Apr 30, 2025 by octopusdeploylabs

    A unique polling subscription ID that can be used by polling tentacles.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as octopusdeploy from "@pulumi/octopusdeploy";
    
    const example = new octopusdeploy.PollingSubscriptionId("example", {});
    const exampleWithDependencies = new octopusdeploy.PollingSubscriptionId("exampleWithDependencies", {dependencies: {
        target: octopusdeploy_kubernetes_agent_deployment_target.example.id,
    }});
    // Usage
    const agent = new octopusdeploy.KubernetesAgentDeploymentTarget("agent", {
        environments: ["environments-1"],
        roles: [
            "role-1",
            "role-2",
        ],
        thumbprint: "96203ED84246201C26A2F4360D7CBC36AC1D232D",
        uri: exampleWithDependencies.pollingUri,
    });
    
    import pulumi
    import pulumi_octopusdeploy as octopusdeploy
    
    example = octopusdeploy.PollingSubscriptionId("example")
    example_with_dependencies = octopusdeploy.PollingSubscriptionId("exampleWithDependencies", dependencies={
        "target": octopusdeploy_kubernetes_agent_deployment_target["example"]["id"],
    })
    # Usage
    agent = octopusdeploy.KubernetesAgentDeploymentTarget("agent",
        environments=["environments-1"],
        roles=[
            "role-1",
            "role-2",
        ],
        thumbprint="96203ED84246201C26A2F4360D7CBC36AC1D232D",
        uri=example_with_dependencies.polling_uri)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/octopusdeploy/octopusdeploy"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := octopusdeploy.NewPollingSubscriptionId(ctx, "example", nil)
    		if err != nil {
    			return err
    		}
    		exampleWithDependencies, err := octopusdeploy.NewPollingSubscriptionId(ctx, "exampleWithDependencies", &octopusdeploy.PollingSubscriptionIdArgs{
    			Dependencies: pulumi.StringMap{
    				"target": pulumi.Any(octopusdeploy_kubernetes_agent_deployment_target.Example.Id),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		// Usage
    		_, err = octopusdeploy.NewKubernetesAgentDeploymentTarget(ctx, "agent", &octopusdeploy.KubernetesAgentDeploymentTargetArgs{
    			Environments: pulumi.StringArray{
    				pulumi.String("environments-1"),
    			},
    			Roles: pulumi.StringArray{
    				pulumi.String("role-1"),
    				pulumi.String("role-2"),
    			},
    			Thumbprint: pulumi.String("96203ED84246201C26A2F4360D7CBC36AC1D232D"),
    			Uri:        exampleWithDependencies.PollingUri,
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Octopusdeploy = Pulumi.Octopusdeploy;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Octopusdeploy.PollingSubscriptionId("example");
    
        var exampleWithDependencies = new Octopusdeploy.PollingSubscriptionId("exampleWithDependencies", new()
        {
            Dependencies = 
            {
                { "target", octopusdeploy_kubernetes_agent_deployment_target.Example.Id },
            },
        });
    
        // Usage
        var agent = new Octopusdeploy.KubernetesAgentDeploymentTarget("agent", new()
        {
            Environments = new[]
            {
                "environments-1",
            },
            Roles = new[]
            {
                "role-1",
                "role-2",
            },
            Thumbprint = "96203ED84246201C26A2F4360D7CBC36AC1D232D",
            Uri = exampleWithDependencies.PollingUri,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.octopusdeploy.PollingSubscriptionId;
    import com.pulumi.octopusdeploy.PollingSubscriptionIdArgs;
    import com.pulumi.octopusdeploy.KubernetesAgentDeploymentTarget;
    import com.pulumi.octopusdeploy.KubernetesAgentDeploymentTargetArgs;
    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) {
            var example = new PollingSubscriptionId("example");
    
            var exampleWithDependencies = new PollingSubscriptionId("exampleWithDependencies", PollingSubscriptionIdArgs.builder()
                .dependencies(Map.of("target", octopusdeploy_kubernetes_agent_deployment_target.example().id()))
                .build());
    
            // Usage
            var agent = new KubernetesAgentDeploymentTarget("agent", KubernetesAgentDeploymentTargetArgs.builder()
                .environments("environments-1")
                .roles(            
                    "role-1",
                    "role-2")
                .thumbprint("96203ED84246201C26A2F4360D7CBC36AC1D232D")
                .uri(exampleWithDependencies.pollingUri())
                .build());
    
        }
    }
    
    resources:
      example:
        type: octopusdeploy:PollingSubscriptionId
      exampleWithDependencies:
        type: octopusdeploy:PollingSubscriptionId
        properties:
          dependencies:
            target: ${octopusdeploy_kubernetes_agent_deployment_target.example.id}
      # Usage
      agent:
        type: octopusdeploy:KubernetesAgentDeploymentTarget
        properties:
          environments:
            - environments-1
          roles:
            - role-1
            - role-2
          thumbprint: 96203ED84246201C26A2F4360D7CBC36AC1D232D
          uri: ${exampleWithDependencies.pollingUri}
    

    Create PollingSubscriptionId Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new PollingSubscriptionId(name: string, args?: PollingSubscriptionIdArgs, opts?: CustomResourceOptions);
    @overload
    def PollingSubscriptionId(resource_name: str,
                              args: Optional[PollingSubscriptionIdArgs] = None,
                              opts: Optional[ResourceOptions] = None)
    
    @overload
    def PollingSubscriptionId(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              dependencies: Optional[Mapping[str, str]] = None)
    func NewPollingSubscriptionId(ctx *Context, name string, args *PollingSubscriptionIdArgs, opts ...ResourceOption) (*PollingSubscriptionId, error)
    public PollingSubscriptionId(string name, PollingSubscriptionIdArgs? args = null, CustomResourceOptions? opts = null)
    public PollingSubscriptionId(String name, PollingSubscriptionIdArgs args)
    public PollingSubscriptionId(String name, PollingSubscriptionIdArgs args, CustomResourceOptions options)
    
    type: octopusdeploy:PollingSubscriptionId
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args PollingSubscriptionIdArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args PollingSubscriptionIdArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args PollingSubscriptionIdArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PollingSubscriptionIdArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PollingSubscriptionIdArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var pollingSubscriptionIdResource = new Octopusdeploy.PollingSubscriptionId("pollingSubscriptionIdResource", new()
    {
        Dependencies = 
        {
            { "string", "string" },
        },
    });
    
    example, err := octopusdeploy.NewPollingSubscriptionId(ctx, "pollingSubscriptionIdResource", &octopusdeploy.PollingSubscriptionIdArgs{
    	Dependencies: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var pollingSubscriptionIdResource = new PollingSubscriptionId("pollingSubscriptionIdResource", PollingSubscriptionIdArgs.builder()
        .dependencies(Map.of("string", "string"))
        .build());
    
    polling_subscription_id_resource = octopusdeploy.PollingSubscriptionId("pollingSubscriptionIdResource", dependencies={
        "string": "string",
    })
    
    const pollingSubscriptionIdResource = new octopusdeploy.PollingSubscriptionId("pollingSubscriptionIdResource", {dependencies: {
        string: "string",
    }});
    
    type: octopusdeploy:PollingSubscriptionId
    properties:
        dependencies:
            string: string
    

    PollingSubscriptionId Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The PollingSubscriptionId resource accepts the following input properties:

    Dependencies Dictionary<string, string>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    Dependencies map[string]string
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    dependencies Map<String,String>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    dependencies {[key: string]: string}
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    dependencies Mapping[str, str]
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    dependencies Map<String>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the PollingSubscriptionId resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    PollingUri string
    The URI of the polling subscription ID.
    Id string
    The provider-assigned unique ID for this managed resource.
    PollingUri string
    The URI of the polling subscription ID.
    id String
    The provider-assigned unique ID for this managed resource.
    pollingUri String
    The URI of the polling subscription ID.
    id string
    The provider-assigned unique ID for this managed resource.
    pollingUri string
    The URI of the polling subscription ID.
    id str
    The provider-assigned unique ID for this managed resource.
    polling_uri str
    The URI of the polling subscription ID.
    id String
    The provider-assigned unique ID for this managed resource.
    pollingUri String
    The URI of the polling subscription ID.

    Look up Existing PollingSubscriptionId Resource

    Get an existing PollingSubscriptionId resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: PollingSubscriptionIdState, opts?: CustomResourceOptions): PollingSubscriptionId
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            dependencies: Optional[Mapping[str, str]] = None,
            polling_uri: Optional[str] = None) -> PollingSubscriptionId
    func GetPollingSubscriptionId(ctx *Context, name string, id IDInput, state *PollingSubscriptionIdState, opts ...ResourceOption) (*PollingSubscriptionId, error)
    public static PollingSubscriptionId Get(string name, Input<string> id, PollingSubscriptionIdState? state, CustomResourceOptions? opts = null)
    public static PollingSubscriptionId get(String name, Output<String> id, PollingSubscriptionIdState state, CustomResourceOptions options)
    resources:  _:    type: octopusdeploy:PollingSubscriptionId    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Dependencies Dictionary<string, string>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    PollingUri string
    The URI of the polling subscription ID.
    Dependencies map[string]string
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    PollingUri string
    The URI of the polling subscription ID.
    dependencies Map<String,String>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    pollingUri String
    The URI of the polling subscription ID.
    dependencies {[key: string]: string}
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    pollingUri string
    The URI of the polling subscription ID.
    dependencies Mapping[str, str]
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    polling_uri str
    The URI of the polling subscription ID.
    dependencies Map<String>
    Optional map of dependencies that when modified will trigger a re-creation of this resource.
    pollingUri String
    The URI of the polling subscription ID.

    Package Details

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