1. Packages
  2. Harness
  3. API Docs
  4. platform
  5. TerraformCloudConnector
Harness v0.0.6 published on Saturday, Jul 1, 2023 by lbrlabs

harness.platform.TerraformCloudConnector

Explore with Pulumi AI

harness logo
Harness v0.0.6 published on Saturday, Jul 1, 2023 by lbrlabs

    Import

    Import account level Terraform Cloud provider connector

     $ pulumi import harness:platform/terraformCloudConnector:TerraformCloudConnector example <connector_id>
    

    Import org level Terraform Cloud provider connector

     $ pulumi import harness:platform/terraformCloudConnector:TerraformCloudConnector example <ord_id>/<connector_id>
    

    Import project level Terraform Cloud provider connector

     $ pulumi import harness:platform/terraformCloudConnector:TerraformCloudConnector example <org_id>/<project_id>/<connector_id>
    

    Example Usage

    Coming soon!

    Coming soon!

    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.harness.platform.TerraformCloudConnector;
    import com.pulumi.harness.platform.TerraformCloudConnectorArgs;
    import com.pulumi.harness.platform.inputs.TerraformCloudConnectorCredentialsArgs;
    import com.pulumi.harness.platform.inputs.TerraformCloudConnectorCredentialsApiTokenArgs;
    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 terraformCloud = new TerraformCloudConnector("terraformCloud", TerraformCloudConnectorArgs.builder()        
                .credentials(TerraformCloudConnectorCredentialsArgs.builder()
                    .apiToken(TerraformCloudConnectorCredentialsApiTokenArgs.builder()
                        .apiTokenRef("account.TEST_terraform_cloud_api_token")
                        .build())
                    .build())
                .delegateSelectors("harness-delegate")
                .description("description of terraform cloud connector")
                .executeOnDelegate(false)
                .identifier("example_terraform_cloud_connector")
                .tags("foo:bar")
                .url("https://app.terraform.io/")
                .build());
    
        }
    }
    

    Coming soon!

    Coming soon!

    resources:
      terraformCloud:
        type: harness:platform:TerraformCloudConnector
        properties:
          credentials:
            apiToken:
              apiTokenRef: account.TEST_terraform_cloud_api_token
          delegateSelectors:
            - harness-delegate
          description: description of terraform cloud connector
          executeOnDelegate: false
          identifier: example_terraform_cloud_connector
          tags:
            - foo:bar
          url: https://app.terraform.io/
    

    Create TerraformCloudConnector Resource

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

    Constructor syntax

    new TerraformCloudConnector(name: string, args: TerraformCloudConnectorArgs, opts?: CustomResourceOptions);
    @overload
    def TerraformCloudConnector(resource_name: str,
                                args: TerraformCloudConnectorArgs,
                                opts: Optional[ResourceOptions] = None)
    
    @overload
    def TerraformCloudConnector(resource_name: str,
                                opts: Optional[ResourceOptions] = None,
                                credentials: Optional[TerraformCloudConnectorCredentialsArgs] = None,
                                identifier: Optional[str] = None,
                                url: Optional[str] = None,
                                delegate_selectors: Optional[Sequence[str]] = None,
                                description: Optional[str] = None,
                                name: Optional[str] = None,
                                org_id: Optional[str] = None,
                                project_id: Optional[str] = None,
                                tags: Optional[Sequence[str]] = None)
    func NewTerraformCloudConnector(ctx *Context, name string, args TerraformCloudConnectorArgs, opts ...ResourceOption) (*TerraformCloudConnector, error)
    public TerraformCloudConnector(string name, TerraformCloudConnectorArgs args, CustomResourceOptions? opts = null)
    public TerraformCloudConnector(String name, TerraformCloudConnectorArgs args)
    public TerraformCloudConnector(String name, TerraformCloudConnectorArgs args, CustomResourceOptions options)
    
    type: harness:platform:TerraformCloudConnector
    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 TerraformCloudConnectorArgs
    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 TerraformCloudConnectorArgs
    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 TerraformCloudConnectorArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TerraformCloudConnectorArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TerraformCloudConnectorArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

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

    var terraformCloudConnectorResource = new Harness.Platform.TerraformCloudConnector("terraformCloudConnectorResource", new()
    {
        Credentials = new Harness.Platform.Inputs.TerraformCloudConnectorCredentialsArgs
        {
            ApiToken = new Harness.Platform.Inputs.TerraformCloudConnectorCredentialsApiTokenArgs
            {
                ApiTokenRef = "string",
            },
        },
        Identifier = "string",
        Url = "string",
        DelegateSelectors = new[]
        {
            "string",
        },
        Description = "string",
        Name = "string",
        OrgId = "string",
        ProjectId = "string",
        Tags = new[]
        {
            "string",
        },
    });
    
    example, err := platform.NewTerraformCloudConnector(ctx, "terraformCloudConnectorResource", &platform.TerraformCloudConnectorArgs{
    	Credentials: &platform.TerraformCloudConnectorCredentialsArgs{
    		ApiToken: &platform.TerraformCloudConnectorCredentialsApiTokenArgs{
    			ApiTokenRef: pulumi.String("string"),
    		},
    	},
    	Identifier: pulumi.String("string"),
    	Url:        pulumi.String("string"),
    	DelegateSelectors: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    	OrgId:       pulumi.String("string"),
    	ProjectId:   pulumi.String("string"),
    	Tags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var terraformCloudConnectorResource = new TerraformCloudConnector("terraformCloudConnectorResource", TerraformCloudConnectorArgs.builder()        
        .credentials(TerraformCloudConnectorCredentialsArgs.builder()
            .apiToken(TerraformCloudConnectorCredentialsApiTokenArgs.builder()
                .apiTokenRef("string")
                .build())
            .build())
        .identifier("string")
        .url("string")
        .delegateSelectors("string")
        .description("string")
        .name("string")
        .orgId("string")
        .projectId("string")
        .tags("string")
        .build());
    
    terraform_cloud_connector_resource = harness.platform.TerraformCloudConnector("terraformCloudConnectorResource",
        credentials=harness.platform.TerraformCloudConnectorCredentialsArgs(
            api_token=harness.platform.TerraformCloudConnectorCredentialsApiTokenArgs(
                api_token_ref="string",
            ),
        ),
        identifier="string",
        url="string",
        delegate_selectors=["string"],
        description="string",
        name="string",
        org_id="string",
        project_id="string",
        tags=["string"])
    
    const terraformCloudConnectorResource = new harness.platform.TerraformCloudConnector("terraformCloudConnectorResource", {
        credentials: {
            apiToken: {
                apiTokenRef: "string",
            },
        },
        identifier: "string",
        url: "string",
        delegateSelectors: ["string"],
        description: "string",
        name: "string",
        orgId: "string",
        projectId: "string",
        tags: ["string"],
    });
    
    type: harness:platform:TerraformCloudConnector
    properties:
        credentials:
            apiToken:
                apiTokenRef: string
        delegateSelectors:
            - string
        description: string
        identifier: string
        name: string
        orgId: string
        projectId: string
        tags:
            - string
        url: string
    

    TerraformCloudConnector Resource Properties

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

    Inputs

    The TerraformCloudConnector resource accepts the following input properties:

    Credentials Lbrlabs.PulumiPackage.Harness.Platform.Inputs.TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    Identifier string
    Unique identifier of the resource.
    Url string
    URL of the Terraform Cloud platform.
    DelegateSelectors List<string>
    Connect only using delegates with these tags.
    Description string
    Description of the resource.
    Name string
    Name of the resource.
    OrgId string
    Unique identifier of the organization.
    ProjectId string
    Unique identifier of the project.
    Tags List<string>
    Tags to associate with the resource.
    Credentials TerraformCloudConnectorCredentialsArgs
    Credentials to connect to the Terraform Cloud platform.
    Identifier string
    Unique identifier of the resource.
    Url string
    URL of the Terraform Cloud platform.
    DelegateSelectors []string
    Connect only using delegates with these tags.
    Description string
    Description of the resource.
    Name string
    Name of the resource.
    OrgId string
    Unique identifier of the organization.
    ProjectId string
    Unique identifier of the project.
    Tags []string
    Tags to associate with the resource.
    credentials TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    identifier String
    Unique identifier of the resource.
    url String
    URL of the Terraform Cloud platform.
    delegateSelectors List<String>
    Connect only using delegates with these tags.
    description String
    Description of the resource.
    name String
    Name of the resource.
    orgId String
    Unique identifier of the organization.
    projectId String
    Unique identifier of the project.
    tags List<String>
    Tags to associate with the resource.
    credentials TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    identifier string
    Unique identifier of the resource.
    url string
    URL of the Terraform Cloud platform.
    delegateSelectors string[]
    Connect only using delegates with these tags.
    description string
    Description of the resource.
    name string
    Name of the resource.
    orgId string
    Unique identifier of the organization.
    projectId string
    Unique identifier of the project.
    tags string[]
    Tags to associate with the resource.
    credentials TerraformCloudConnectorCredentialsArgs
    Credentials to connect to the Terraform Cloud platform.
    identifier str
    Unique identifier of the resource.
    url str
    URL of the Terraform Cloud platform.
    delegate_selectors Sequence[str]
    Connect only using delegates with these tags.
    description str
    Description of the resource.
    name str
    Name of the resource.
    org_id str
    Unique identifier of the organization.
    project_id str
    Unique identifier of the project.
    tags Sequence[str]
    Tags to associate with the resource.
    credentials Property Map
    Credentials to connect to the Terraform Cloud platform.
    identifier String
    Unique identifier of the resource.
    url String
    URL of the Terraform Cloud platform.
    delegateSelectors List<String>
    Connect only using delegates with these tags.
    description String
    Description of the resource.
    name String
    Name of the resource.
    orgId String
    Unique identifier of the organization.
    projectId String
    Unique identifier of the project.
    tags List<String>
    Tags to associate with the resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing TerraformCloudConnector Resource

    Get an existing TerraformCloudConnector 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?: TerraformCloudConnectorState, opts?: CustomResourceOptions): TerraformCloudConnector
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            credentials: Optional[TerraformCloudConnectorCredentialsArgs] = None,
            delegate_selectors: Optional[Sequence[str]] = None,
            description: Optional[str] = None,
            identifier: Optional[str] = None,
            name: Optional[str] = None,
            org_id: Optional[str] = None,
            project_id: Optional[str] = None,
            tags: Optional[Sequence[str]] = None,
            url: Optional[str] = None) -> TerraformCloudConnector
    func GetTerraformCloudConnector(ctx *Context, name string, id IDInput, state *TerraformCloudConnectorState, opts ...ResourceOption) (*TerraformCloudConnector, error)
    public static TerraformCloudConnector Get(string name, Input<string> id, TerraformCloudConnectorState? state, CustomResourceOptions? opts = null)
    public static TerraformCloudConnector get(String name, Output<String> id, TerraformCloudConnectorState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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:
    Credentials Lbrlabs.PulumiPackage.Harness.Platform.Inputs.TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    DelegateSelectors List<string>
    Connect only using delegates with these tags.
    Description string
    Description of the resource.
    Identifier string
    Unique identifier of the resource.
    Name string
    Name of the resource.
    OrgId string
    Unique identifier of the organization.
    ProjectId string
    Unique identifier of the project.
    Tags List<string>
    Tags to associate with the resource.
    Url string
    URL of the Terraform Cloud platform.
    Credentials TerraformCloudConnectorCredentialsArgs
    Credentials to connect to the Terraform Cloud platform.
    DelegateSelectors []string
    Connect only using delegates with these tags.
    Description string
    Description of the resource.
    Identifier string
    Unique identifier of the resource.
    Name string
    Name of the resource.
    OrgId string
    Unique identifier of the organization.
    ProjectId string
    Unique identifier of the project.
    Tags []string
    Tags to associate with the resource.
    Url string
    URL of the Terraform Cloud platform.
    credentials TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    delegateSelectors List<String>
    Connect only using delegates with these tags.
    description String
    Description of the resource.
    identifier String
    Unique identifier of the resource.
    name String
    Name of the resource.
    orgId String
    Unique identifier of the organization.
    projectId String
    Unique identifier of the project.
    tags List<String>
    Tags to associate with the resource.
    url String
    URL of the Terraform Cloud platform.
    credentials TerraformCloudConnectorCredentials
    Credentials to connect to the Terraform Cloud platform.
    delegateSelectors string[]
    Connect only using delegates with these tags.
    description string
    Description of the resource.
    identifier string
    Unique identifier of the resource.
    name string
    Name of the resource.
    orgId string
    Unique identifier of the organization.
    projectId string
    Unique identifier of the project.
    tags string[]
    Tags to associate with the resource.
    url string
    URL of the Terraform Cloud platform.
    credentials TerraformCloudConnectorCredentialsArgs
    Credentials to connect to the Terraform Cloud platform.
    delegate_selectors Sequence[str]
    Connect only using delegates with these tags.
    description str
    Description of the resource.
    identifier str
    Unique identifier of the resource.
    name str
    Name of the resource.
    org_id str
    Unique identifier of the organization.
    project_id str
    Unique identifier of the project.
    tags Sequence[str]
    Tags to associate with the resource.
    url str
    URL of the Terraform Cloud platform.
    credentials Property Map
    Credentials to connect to the Terraform Cloud platform.
    delegateSelectors List<String>
    Connect only using delegates with these tags.
    description String
    Description of the resource.
    identifier String
    Unique identifier of the resource.
    name String
    Name of the resource.
    orgId String
    Unique identifier of the organization.
    projectId String
    Unique identifier of the project.
    tags List<String>
    Tags to associate with the resource.
    url String
    URL of the Terraform Cloud platform.

    Supporting Types

    TerraformCloudConnectorCredentials, TerraformCloudConnectorCredentialsArgs

    ApiToken TerraformCloudConnectorCredentialsApiToken
    API token credentials to use for authentication.
    apiToken TerraformCloudConnectorCredentialsApiToken
    API token credentials to use for authentication.
    apiToken TerraformCloudConnectorCredentialsApiToken
    API token credentials to use for authentication.
    api_token TerraformCloudConnectorCredentialsApiToken
    API token credentials to use for authentication.
    apiToken Property Map
    API token credentials to use for authentication.

    TerraformCloudConnectorCredentialsApiToken, TerraformCloudConnectorCredentialsApiTokenArgs

    Package Details

    Repository
    harness lbrlabs/pulumi-harness
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the harness Terraform Provider.
    harness logo
    Harness v0.0.6 published on Saturday, Jul 1, 2023 by lbrlabs