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

harness.platform.EnvironmentGroup

Explore with Pulumi AI

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

    Resource for creating a Harness environment group.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Harness = Lbrlabs.PulumiPackage.Harness;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Harness.Platform.EnvironmentGroup("example", new()
        {
            Color = "#0063F7",
            Identifier = "identifier",
            OrgId = "orgIdentifer",
            ProjectId = "projectIdentifier",
            Yaml = @"  environmentGroup:
        name: ""name""
        identifier: ""identifier""
        description: ""temp""
        orgIdentifier: ""orgIdentifer""
        projectIdentifier: ""projectIdentifier""
        envIdentifiers: []
    
    ",
        });
    
    });
    
    package main
    
    import (
    	"github.com/lbrlabs/pulumi-harness/sdk/go/harness/platform"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := platform.NewEnvironmentGroup(ctx, "example", &platform.EnvironmentGroupArgs{
    			Color:      pulumi.String("#0063F7"),
    			Identifier: pulumi.String("identifier"),
    			OrgId:      pulumi.String("orgIdentifer"),
    			ProjectId:  pulumi.String("projectIdentifier"),
    			Yaml: pulumi.String(`  environmentGroup:
        name: "name"
        identifier: "identifier"
        description: "temp"
        orgIdentifier: "orgIdentifer"
        projectIdentifier: "projectIdentifier"
        envIdentifiers: []
    
    `),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.harness.platform.EnvironmentGroup;
    import com.pulumi.harness.platform.EnvironmentGroupArgs;
    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 EnvironmentGroup("example", EnvironmentGroupArgs.builder()        
                .color("#0063F7")
                .identifier("identifier")
                .orgId("orgIdentifer")
                .projectId("projectIdentifier")
                .yaml("""
      environmentGroup:
        name: "name"
        identifier: "identifier"
        description: "temp"
        orgIdentifier: "orgIdentifer"
        projectIdentifier: "projectIdentifier"
        envIdentifiers: []
    
                """)
                .build());
    
        }
    }
    
    import pulumi
    import lbrlabs_pulumi_harness as harness
    
    example = harness.platform.EnvironmentGroup("example",
        color="#0063F7",
        identifier="identifier",
        org_id="orgIdentifer",
        project_id="projectIdentifier",
        yaml="""  environmentGroup:
        name: "name"
        identifier: "identifier"
        description: "temp"
        orgIdentifier: "orgIdentifer"
        projectIdentifier: "projectIdentifier"
        envIdentifiers: []
    
    """)
    
    import * as pulumi from "@pulumi/pulumi";
    import * as harness from "@lbrlabs/pulumi-harness";
    
    const example = new harness.platform.EnvironmentGroup("example", {
        color: "#0063F7",
        identifier: "identifier",
        orgId: "orgIdentifer",
        projectId: "projectIdentifier",
        yaml: `  environmentGroup:
        name: "name"
        identifier: "identifier"
        description: "temp"
        orgIdentifier: "orgIdentifer"
        projectIdentifier: "projectIdentifier"
        envIdentifiers: []
    
    `,
    });
    
    resources:
      example:
        type: harness:platform:EnvironmentGroup
        properties:
          color: '#0063F7'
          identifier: identifier
          orgId: orgIdentifer
          projectId: projectIdentifier
          yaml: |2+
              environmentGroup:
                name: "name"
                identifier: "identifier"
                description: "temp"
                orgIdentifier: "orgIdentifer"
                projectIdentifier: "projectIdentifier"
                envIdentifiers: []
    

    Create EnvironmentGroup Resource

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

    Constructor syntax

    new EnvironmentGroup(name: string, args: EnvironmentGroupArgs, opts?: CustomResourceOptions);
    @overload
    def EnvironmentGroup(resource_name: str,
                         args: EnvironmentGroupArgs,
                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def EnvironmentGroup(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         identifier: Optional[str] = None,
                         yaml: Optional[str] = None,
                         color: Optional[str] = None,
                         force_delete: Optional[str] = None,
                         org_id: Optional[str] = None,
                         project_id: Optional[str] = None)
    func NewEnvironmentGroup(ctx *Context, name string, args EnvironmentGroupArgs, opts ...ResourceOption) (*EnvironmentGroup, error)
    public EnvironmentGroup(string name, EnvironmentGroupArgs args, CustomResourceOptions? opts = null)
    public EnvironmentGroup(String name, EnvironmentGroupArgs args)
    public EnvironmentGroup(String name, EnvironmentGroupArgs args, CustomResourceOptions options)
    
    type: harness:platform:EnvironmentGroup
    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 EnvironmentGroupArgs
    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 EnvironmentGroupArgs
    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 EnvironmentGroupArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args EnvironmentGroupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args EnvironmentGroupArgs
    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 environmentGroupResource = new Harness.Platform.EnvironmentGroup("environmentGroupResource", new()
    {
        Identifier = "string",
        Yaml = "string",
        Color = "string",
        ForceDelete = "string",
        OrgId = "string",
        ProjectId = "string",
    });
    
    example, err := platform.NewEnvironmentGroup(ctx, "environmentGroupResource", &platform.EnvironmentGroupArgs{
    	Identifier:  pulumi.String("string"),
    	Yaml:        pulumi.String("string"),
    	Color:       pulumi.String("string"),
    	ForceDelete: pulumi.String("string"),
    	OrgId:       pulumi.String("string"),
    	ProjectId:   pulumi.String("string"),
    })
    
    var environmentGroupResource = new EnvironmentGroup("environmentGroupResource", EnvironmentGroupArgs.builder()        
        .identifier("string")
        .yaml("string")
        .color("string")
        .forceDelete("string")
        .orgId("string")
        .projectId("string")
        .build());
    
    environment_group_resource = harness.platform.EnvironmentGroup("environmentGroupResource",
        identifier="string",
        yaml="string",
        color="string",
        force_delete="string",
        org_id="string",
        project_id="string")
    
    const environmentGroupResource = new harness.platform.EnvironmentGroup("environmentGroupResource", {
        identifier: "string",
        yaml: "string",
        color: "string",
        forceDelete: "string",
        orgId: "string",
        projectId: "string",
    });
    
    type: harness:platform:EnvironmentGroup
    properties:
        color: string
        forceDelete: string
        identifier: string
        orgId: string
        projectId: string
        yaml: string
    

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

    Identifier string
    identifier of the environment group.
    Yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    Color string
    Color of the environment group.
    ForceDelete string
    Enable this flag for force deletion of environment group
    OrgId string
    org_id of the environment group.
    ProjectId string
    project_id of the environment group.
    Identifier string
    identifier of the environment group.
    Yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    Color string
    Color of the environment group.
    ForceDelete string
    Enable this flag for force deletion of environment group
    OrgId string
    org_id of the environment group.
    ProjectId string
    project_id of the environment group.
    identifier String
    identifier of the environment group.
    yaml String
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color String
    Color of the environment group.
    forceDelete String
    Enable this flag for force deletion of environment group
    orgId String
    org_id of the environment group.
    projectId String
    project_id of the environment group.
    identifier string
    identifier of the environment group.
    yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color string
    Color of the environment group.
    forceDelete string
    Enable this flag for force deletion of environment group
    orgId string
    org_id of the environment group.
    projectId string
    project_id of the environment group.
    identifier str
    identifier of the environment group.
    yaml str
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color str
    Color of the environment group.
    force_delete str
    Enable this flag for force deletion of environment group
    org_id str
    org_id of the environment group.
    project_id str
    project_id of the environment group.
    identifier String
    identifier of the environment group.
    yaml String
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color String
    Color of the environment group.
    forceDelete String
    Enable this flag for force deletion of environment group
    orgId String
    org_id of the environment group.
    projectId String
    project_id of the environment group.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the EnvironmentGroup 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 EnvironmentGroup Resource

    Get an existing EnvironmentGroup 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?: EnvironmentGroupState, opts?: CustomResourceOptions): EnvironmentGroup
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            color: Optional[str] = None,
            force_delete: Optional[str] = None,
            identifier: Optional[str] = None,
            org_id: Optional[str] = None,
            project_id: Optional[str] = None,
            yaml: Optional[str] = None) -> EnvironmentGroup
    func GetEnvironmentGroup(ctx *Context, name string, id IDInput, state *EnvironmentGroupState, opts ...ResourceOption) (*EnvironmentGroup, error)
    public static EnvironmentGroup Get(string name, Input<string> id, EnvironmentGroupState? state, CustomResourceOptions? opts = null)
    public static EnvironmentGroup get(String name, Output<String> id, EnvironmentGroupState 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:
    Color string
    Color of the environment group.
    ForceDelete string
    Enable this flag for force deletion of environment group
    Identifier string
    identifier of the environment group.
    OrgId string
    org_id of the environment group.
    ProjectId string
    project_id of the environment group.
    Yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    Color string
    Color of the environment group.
    ForceDelete string
    Enable this flag for force deletion of environment group
    Identifier string
    identifier of the environment group.
    OrgId string
    org_id of the environment group.
    ProjectId string
    project_id of the environment group.
    Yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color String
    Color of the environment group.
    forceDelete String
    Enable this flag for force deletion of environment group
    identifier String
    identifier of the environment group.
    orgId String
    org_id of the environment group.
    projectId String
    project_id of the environment group.
    yaml String
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color string
    Color of the environment group.
    forceDelete string
    Enable this flag for force deletion of environment group
    identifier string
    identifier of the environment group.
    orgId string
    org_id of the environment group.
    projectId string
    project_id of the environment group.
    yaml string
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color str
    Color of the environment group.
    force_delete str
    Enable this flag for force deletion of environment group
    identifier str
    identifier of the environment group.
    org_id str
    org_id of the environment group.
    project_id str
    project_id of the environment group.
    yaml str
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.
    color String
    Color of the environment group.
    forceDelete String
    Enable this flag for force deletion of environment group
    identifier String
    identifier of the environment group.
    orgId String
    org_id of the environment group.
    projectId String
    project_id of the environment group.
    yaml String
    Env group YAML. In YAML, to reference an entity at the organization scope, prefix 'org' to the expression: org.{identifier}. To reference an entity at the account scope, prefix 'account` to the expression: account.{identifier}. For eg, to reference a connector with identifier 'connectorId' at the organization scope in a stage mention it as connectorRef: org.connectorId.

    Import

    Import using the environment group id.

     $ pulumi import harness:platform/environmentGroup:EnvironmentGroup example <org_id>/<project_id>/<environment_group_id>
    

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

    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