1. Packages
  2. Harness Provider
  3. API Docs
  4. Application
Harness v0.4.4 published on Tuesday, Nov 12, 2024 by Pulumi

harness.Application

Explore with Pulumi AI

harness logo
Harness v0.4.4 published on Tuesday, Nov 12, 2024 by Pulumi

    Resource for creating a Harness application

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as harness from "@pulumi/harness";
    
    const myapp = new harness.Application("myapp", {
        name: "My Application",
        description: "This is my first Harness application",
        tags: [
            "mytag:myvalue",
            "team:development",
        ],
    });
    
    import pulumi
    import pulumi_harness as harness
    
    myapp = harness.Application("myapp",
        name="My Application",
        description="This is my first Harness application",
        tags=[
            "mytag:myvalue",
            "team:development",
        ])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-harness/sdk/go/harness"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := harness.NewApplication(ctx, "myapp", &harness.ApplicationArgs{
    			Name:        pulumi.String("My Application"),
    			Description: pulumi.String("This is my first Harness application"),
    			Tags: pulumi.StringArray{
    				pulumi.String("mytag:myvalue"),
    				pulumi.String("team:development"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Harness = Pulumi.Harness;
    
    return await Deployment.RunAsync(() => 
    {
        var myapp = new Harness.Application("myapp", new()
        {
            Name = "My Application",
            Description = "This is my first Harness application",
            Tags = new[]
            {
                "mytag:myvalue",
                "team:development",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.harness.Application;
    import com.pulumi.harness.ApplicationArgs;
    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 myapp = new Application("myapp", ApplicationArgs.builder()
                .name("My Application")
                .description("This is my first Harness application")
                .tags(            
                    "mytag:myvalue",
                    "team:development")
                .build());
    
        }
    }
    
    resources:
      myapp:
        type: harness:Application
        properties:
          name: My Application
          description: This is my first Harness application
          tags:
            - mytag:myvalue
            - team:development
    

    Create Application Resource

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

    Constructor syntax

    new Application(name: string, args?: ApplicationArgs, opts?: CustomResourceOptions);
    @overload
    def Application(resource_name: str,
                    args: Optional[ApplicationArgs] = None,
                    opts: Optional[ResourceOptions] = None)
    
    @overload
    def Application(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    description: Optional[str] = None,
                    is_manual_trigger_authorized: Optional[bool] = None,
                    name: Optional[str] = None,
                    tags: Optional[Sequence[str]] = None)
    func NewApplication(ctx *Context, name string, args *ApplicationArgs, opts ...ResourceOption) (*Application, error)
    public Application(string name, ApplicationArgs? args = null, CustomResourceOptions? opts = null)
    public Application(String name, ApplicationArgs args)
    public Application(String name, ApplicationArgs args, CustomResourceOptions options)
    
    type: harness:Application
    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 ApplicationArgs
    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 ApplicationArgs
    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 ApplicationArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ApplicationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ApplicationArgs
    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 applicationResource = new Harness.Application("applicationResource", new()
    {
        Description = "string",
        IsManualTriggerAuthorized = false,
        Name = "string",
        Tags = new[]
        {
            "string",
        },
    });
    
    example, err := harness.NewApplication(ctx, "applicationResource", &harness.ApplicationArgs{
    	Description:               pulumi.String("string"),
    	IsManualTriggerAuthorized: pulumi.Bool(false),
    	Name:                      pulumi.String("string"),
    	Tags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var applicationResource = new Application("applicationResource", ApplicationArgs.builder()
        .description("string")
        .isManualTriggerAuthorized(false)
        .name("string")
        .tags("string")
        .build());
    
    application_resource = harness.Application("applicationResource",
        description="string",
        is_manual_trigger_authorized=False,
        name="string",
        tags=["string"])
    
    const applicationResource = new harness.Application("applicationResource", {
        description: "string",
        isManualTriggerAuthorized: false,
        name: "string",
        tags: ["string"],
    });
    
    type: harness:Application
    properties:
        description: string
        isManualTriggerAuthorized: false
        name: string
        tags:
            - string
    

    Application 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 Application resource accepts the following input properties:

    Description string
    The application description
    IsManualTriggerAuthorized bool
    When this is set to true, all manual triggers will require API Key authorization
    Name string
    The name of the application
    Tags List<string>
    Tags to associate with the resource.
    Description string
    The application description
    IsManualTriggerAuthorized bool
    When this is set to true, all manual triggers will require API Key authorization
    Name string
    The name of the application
    Tags []string
    Tags to associate with the resource.
    description String
    The application description
    isManualTriggerAuthorized Boolean
    When this is set to true, all manual triggers will require API Key authorization
    name String
    The name of the application
    tags List<String>
    Tags to associate with the resource.
    description string
    The application description
    isManualTriggerAuthorized boolean
    When this is set to true, all manual triggers will require API Key authorization
    name string
    The name of the application
    tags string[]
    Tags to associate with the resource.
    description str
    The application description
    is_manual_trigger_authorized bool
    When this is set to true, all manual triggers will require API Key authorization
    name str
    The name of the application
    tags Sequence[str]
    Tags to associate with the resource.
    description String
    The application description
    isManualTriggerAuthorized Boolean
    When this is set to true, all manual triggers will require API Key authorization
    name String
    The name of the application
    tags List<String>
    Tags to associate with the resource.

    Outputs

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

    GitSyncConnectorId string
    The id of the git sync connector
    GitSyncEnabled bool
    True if git sync is enabled on this application
    Id string
    The provider-assigned unique ID for this managed resource.
    GitSyncConnectorId string
    The id of the git sync connector
    GitSyncEnabled bool
    True if git sync is enabled on this application
    Id string
    The provider-assigned unique ID for this managed resource.
    gitSyncConnectorId String
    The id of the git sync connector
    gitSyncEnabled Boolean
    True if git sync is enabled on this application
    id String
    The provider-assigned unique ID for this managed resource.
    gitSyncConnectorId string
    The id of the git sync connector
    gitSyncEnabled boolean
    True if git sync is enabled on this application
    id string
    The provider-assigned unique ID for this managed resource.
    git_sync_connector_id str
    The id of the git sync connector
    git_sync_enabled bool
    True if git sync is enabled on this application
    id str
    The provider-assigned unique ID for this managed resource.
    gitSyncConnectorId String
    The id of the git sync connector
    gitSyncEnabled Boolean
    True if git sync is enabled on this application
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Application Resource

    Get an existing Application 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?: ApplicationState, opts?: CustomResourceOptions): Application
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            git_sync_connector_id: Optional[str] = None,
            git_sync_enabled: Optional[bool] = None,
            is_manual_trigger_authorized: Optional[bool] = None,
            name: Optional[str] = None,
            tags: Optional[Sequence[str]] = None) -> Application
    func GetApplication(ctx *Context, name string, id IDInput, state *ApplicationState, opts ...ResourceOption) (*Application, error)
    public static Application Get(string name, Input<string> id, ApplicationState? state, CustomResourceOptions? opts = null)
    public static Application get(String name, Output<String> id, ApplicationState 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:
    Description string
    The application description
    GitSyncConnectorId string
    The id of the git sync connector
    GitSyncEnabled bool
    True if git sync is enabled on this application
    IsManualTriggerAuthorized bool
    When this is set to true, all manual triggers will require API Key authorization
    Name string
    The name of the application
    Tags List<string>
    Tags to associate with the resource.
    Description string
    The application description
    GitSyncConnectorId string
    The id of the git sync connector
    GitSyncEnabled bool
    True if git sync is enabled on this application
    IsManualTriggerAuthorized bool
    When this is set to true, all manual triggers will require API Key authorization
    Name string
    The name of the application
    Tags []string
    Tags to associate with the resource.
    description String
    The application description
    gitSyncConnectorId String
    The id of the git sync connector
    gitSyncEnabled Boolean
    True if git sync is enabled on this application
    isManualTriggerAuthorized Boolean
    When this is set to true, all manual triggers will require API Key authorization
    name String
    The name of the application
    tags List<String>
    Tags to associate with the resource.
    description string
    The application description
    gitSyncConnectorId string
    The id of the git sync connector
    gitSyncEnabled boolean
    True if git sync is enabled on this application
    isManualTriggerAuthorized boolean
    When this is set to true, all manual triggers will require API Key authorization
    name string
    The name of the application
    tags string[]
    Tags to associate with the resource.
    description str
    The application description
    git_sync_connector_id str
    The id of the git sync connector
    git_sync_enabled bool
    True if git sync is enabled on this application
    is_manual_trigger_authorized bool
    When this is set to true, all manual triggers will require API Key authorization
    name str
    The name of the application
    tags Sequence[str]
    Tags to associate with the resource.
    description String
    The application description
    gitSyncConnectorId String
    The id of the git sync connector
    gitSyncEnabled Boolean
    True if git sync is enabled on this application
    isManualTriggerAuthorized Boolean
    When this is set to true, all manual triggers will require API Key authorization
    name String
    The name of the application
    tags List<String>
    Tags to associate with the resource.

    Import

    Import using the Harness application id

    $ pulumi import harness:index/application:Application myapp Xyz123
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    harness pulumi/pulumi-harness
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the harness Terraform Provider.
    harness logo
    Harness v0.4.4 published on Tuesday, Nov 12, 2024 by Pulumi