Resource for creating IDP environments.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as harness from "@pulumi/harness";
const test = new harness.platform.IdpEnvironment("test", {
identifier: "identifier",
orgId: "org_id",
projectId: "project_id",
name: "test",
owner: "group:account/_account_all_users",
blueprintIdentifier: "blueprint_identifier",
blueprintVersion: "v1.0.0",
targetState: "running",
basedOn: "org_id.project_id/environment_identifier",
overrides: `config: {}
entities: {}
`,
inputs: "ttl: 1h30m\n",
});
import pulumi
import pulumi_harness as harness
test = harness.platform.IdpEnvironment("test",
identifier="identifier",
org_id="org_id",
project_id="project_id",
name="test",
owner="group:account/_account_all_users",
blueprint_identifier="blueprint_identifier",
blueprint_version="v1.0.0",
target_state="running",
based_on="org_id.project_id/environment_identifier",
overrides="""config: {}
entities: {}
""",
inputs="ttl: 1h30m\n")
package main
import (
"github.com/pulumi/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.NewIdpEnvironment(ctx, "test", &platform.IdpEnvironmentArgs{
Identifier: pulumi.String("identifier"),
OrgId: pulumi.String("org_id"),
ProjectId: pulumi.String("project_id"),
Name: pulumi.String("test"),
Owner: pulumi.String("group:account/_account_all_users"),
BlueprintIdentifier: pulumi.String("blueprint_identifier"),
BlueprintVersion: pulumi.String("v1.0.0"),
TargetState: pulumi.String("running"),
BasedOn: pulumi.String("org_id.project_id/environment_identifier"),
Overrides: pulumi.String("config: {}\nentities: {}\n"),
Inputs: pulumi.String("ttl: 1h30m\n"),
})
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 test = new Harness.Platform.IdpEnvironment("test", new()
{
Identifier = "identifier",
OrgId = "org_id",
ProjectId = "project_id",
Name = "test",
Owner = "group:account/_account_all_users",
BlueprintIdentifier = "blueprint_identifier",
BlueprintVersion = "v1.0.0",
TargetState = "running",
BasedOn = "org_id.project_id/environment_identifier",
Overrides = @"config: {}
entities: {}
",
Inputs = @"ttl: 1h30m
",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.harness.platform.IdpEnvironment;
import com.pulumi.harness.platform.IdpEnvironmentArgs;
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 test = new IdpEnvironment("test", IdpEnvironmentArgs.builder()
.identifier("identifier")
.orgId("org_id")
.projectId("project_id")
.name("test")
.owner("group:account/_account_all_users")
.blueprintIdentifier("blueprint_identifier")
.blueprintVersion("v1.0.0")
.targetState("running")
.basedOn("org_id.project_id/environment_identifier")
.overrides("""
config: {}
entities: {}
""")
.inputs("""
ttl: 1h30m
""")
.build());
}
}
resources:
test:
type: harness:platform:IdpEnvironment
properties:
identifier: identifier
orgId: org_id
projectId: project_id
name: test
owner: group:account/_account_all_users
blueprintIdentifier: blueprint_identifier
blueprintVersion: v1.0.0
targetState: running
basedOn: org_id.project_id/environment_identifier
overrides: |
config: {}
entities: {}
inputs: |
ttl: 1h30m
Create IdpEnvironment Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new IdpEnvironment(name: string, args: IdpEnvironmentArgs, opts?: CustomResourceOptions);@overload
def IdpEnvironment(resource_name: str,
args: IdpEnvironmentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def IdpEnvironment(resource_name: str,
opts: Optional[ResourceOptions] = None,
blueprint_identifier: Optional[str] = None,
blueprint_version: Optional[str] = None,
identifier: Optional[str] = None,
org_id: Optional[str] = None,
overrides: Optional[str] = None,
owner: Optional[str] = None,
project_id: Optional[str] = None,
based_on: Optional[str] = None,
inputs: Optional[str] = None,
name: Optional[str] = None,
target_state: Optional[str] = None)func NewIdpEnvironment(ctx *Context, name string, args IdpEnvironmentArgs, opts ...ResourceOption) (*IdpEnvironment, error)public IdpEnvironment(string name, IdpEnvironmentArgs args, CustomResourceOptions? opts = null)
public IdpEnvironment(String name, IdpEnvironmentArgs args)
public IdpEnvironment(String name, IdpEnvironmentArgs args, CustomResourceOptions options)
type: harness:platform:IdpEnvironment
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 IdpEnvironmentArgs
- 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 IdpEnvironmentArgs
- 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 IdpEnvironmentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args IdpEnvironmentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args IdpEnvironmentArgs
- 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 idpEnvironmentResource = new Harness.Platform.IdpEnvironment("idpEnvironmentResource", new()
{
BlueprintIdentifier = "string",
BlueprintVersion = "string",
Identifier = "string",
OrgId = "string",
Overrides = "string",
Owner = "string",
ProjectId = "string",
BasedOn = "string",
Inputs = "string",
Name = "string",
TargetState = "string",
});
example, err := platform.NewIdpEnvironment(ctx, "idpEnvironmentResource", &platform.IdpEnvironmentArgs{
BlueprintIdentifier: pulumi.String("string"),
BlueprintVersion: pulumi.String("string"),
Identifier: pulumi.String("string"),
OrgId: pulumi.String("string"),
Overrides: pulumi.String("string"),
Owner: pulumi.String("string"),
ProjectId: pulumi.String("string"),
BasedOn: pulumi.String("string"),
Inputs: pulumi.String("string"),
Name: pulumi.String("string"),
TargetState: pulumi.String("string"),
})
var idpEnvironmentResource = new IdpEnvironment("idpEnvironmentResource", IdpEnvironmentArgs.builder()
.blueprintIdentifier("string")
.blueprintVersion("string")
.identifier("string")
.orgId("string")
.overrides("string")
.owner("string")
.projectId("string")
.basedOn("string")
.inputs("string")
.name("string")
.targetState("string")
.build());
idp_environment_resource = harness.platform.IdpEnvironment("idpEnvironmentResource",
blueprint_identifier="string",
blueprint_version="string",
identifier="string",
org_id="string",
overrides="string",
owner="string",
project_id="string",
based_on="string",
inputs="string",
name="string",
target_state="string")
const idpEnvironmentResource = new harness.platform.IdpEnvironment("idpEnvironmentResource", {
blueprintIdentifier: "string",
blueprintVersion: "string",
identifier: "string",
orgId: "string",
overrides: "string",
owner: "string",
projectId: "string",
basedOn: "string",
inputs: "string",
name: "string",
targetState: "string",
});
type: harness:platform:IdpEnvironment
properties:
basedOn: string
blueprintIdentifier: string
blueprintVersion: string
identifier: string
inputs: string
name: string
orgId: string
overrides: string
owner: string
projectId: string
targetState: string
IdpEnvironment 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 IdpEnvironment resource accepts the following input properties:
- Blueprint
Identifier string - Blueprint to base the environment on
- Blueprint
Version string - Version of the blueprint to base the environment on
- Identifier string
- Unique identifier of the resource.
- Org
Id string - Unique identifier of the organization.
- Overrides string
- Overrides for environment blueprint inputs in YAML format
- Owner string
- Owner of the environment
- Project
Id string - Unique identifier of the project.
- Based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- Inputs string
- Additional inputs for controlling the environment in YAML format
- Name string
- Name of the resource.
- Target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- Blueprint
Identifier string - Blueprint to base the environment on
- Blueprint
Version string - Version of the blueprint to base the environment on
- Identifier string
- Unique identifier of the resource.
- Org
Id string - Unique identifier of the organization.
- Overrides string
- Overrides for environment blueprint inputs in YAML format
- Owner string
- Owner of the environment
- Project
Id string - Unique identifier of the project.
- Based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- Inputs string
- Additional inputs for controlling the environment in YAML format
- Name string
- Name of the resource.
- Target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- blueprint
Identifier String - Blueprint to base the environment on
- blueprint
Version String - Version of the blueprint to base the environment on
- identifier String
- Unique identifier of the resource.
- org
Id String - Unique identifier of the organization.
- overrides String
- Overrides for environment blueprint inputs in YAML format
- owner String
- Owner of the environment
- project
Id String - Unique identifier of the project.
- based
On String - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- inputs String
- Additional inputs for controlling the environment in YAML format
- name String
- Name of the resource.
- target
State String - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- blueprint
Identifier string - Blueprint to base the environment on
- blueprint
Version string - Version of the blueprint to base the environment on
- identifier string
- Unique identifier of the resource.
- org
Id string - Unique identifier of the organization.
- overrides string
- Overrides for environment blueprint inputs in YAML format
- owner string
- Owner of the environment
- project
Id string - Unique identifier of the project.
- based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- inputs string
- Additional inputs for controlling the environment in YAML format
- name string
- Name of the resource.
- target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- blueprint_
identifier str - Blueprint to base the environment on
- blueprint_
version str - Version of the blueprint to base the environment on
- identifier str
- Unique identifier of the resource.
- org_
id str - Unique identifier of the organization.
- overrides str
- Overrides for environment blueprint inputs in YAML format
- owner str
- Owner of the environment
- project_
id str - Unique identifier of the project.
- based_
on str - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- inputs str
- Additional inputs for controlling the environment in YAML format
- name str
- Name of the resource.
- target_
state str - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- blueprint
Identifier String - Blueprint to base the environment on
- blueprint
Version String - Version of the blueprint to base the environment on
- identifier String
- Unique identifier of the resource.
- org
Id String - Unique identifier of the organization.
- overrides String
- Overrides for environment blueprint inputs in YAML format
- owner String
- Owner of the environment
- project
Id String - Unique identifier of the project.
- based
On String - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- inputs String
- Additional inputs for controlling the environment in YAML format
- name String
- Name of the resource.
- target
State String - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
Outputs
All input properties are implicitly available as output properties. Additionally, the IdpEnvironment 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 IdpEnvironment Resource
Get an existing IdpEnvironment 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?: IdpEnvironmentState, opts?: CustomResourceOptions): IdpEnvironment@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
based_on: Optional[str] = None,
blueprint_identifier: Optional[str] = None,
blueprint_version: Optional[str] = None,
identifier: Optional[str] = None,
inputs: Optional[str] = None,
name: Optional[str] = None,
org_id: Optional[str] = None,
overrides: Optional[str] = None,
owner: Optional[str] = None,
project_id: Optional[str] = None,
target_state: Optional[str] = None) -> IdpEnvironmentfunc GetIdpEnvironment(ctx *Context, name string, id IDInput, state *IdpEnvironmentState, opts ...ResourceOption) (*IdpEnvironment, error)public static IdpEnvironment Get(string name, Input<string> id, IdpEnvironmentState? state, CustomResourceOptions? opts = null)public static IdpEnvironment get(String name, Output<String> id, IdpEnvironmentState state, CustomResourceOptions options)resources: _: type: harness:platform:IdpEnvironment 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.
- Based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- Blueprint
Identifier string - Blueprint to base the environment on
- Blueprint
Version string - Version of the blueprint to base the environment on
- Identifier string
- Unique identifier of the resource.
- Inputs string
- Additional inputs for controlling the environment in YAML format
- Name string
- Name of the resource.
- Org
Id string - Unique identifier of the organization.
- Overrides string
- Overrides for environment blueprint inputs in YAML format
- Owner string
- Owner of the environment
- Project
Id string - Unique identifier of the project.
- Target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- Based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- Blueprint
Identifier string - Blueprint to base the environment on
- Blueprint
Version string - Version of the blueprint to base the environment on
- Identifier string
- Unique identifier of the resource.
- Inputs string
- Additional inputs for controlling the environment in YAML format
- Name string
- Name of the resource.
- Org
Id string - Unique identifier of the organization.
- Overrides string
- Overrides for environment blueprint inputs in YAML format
- Owner string
- Owner of the environment
- Project
Id string - Unique identifier of the project.
- Target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- based
On String - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- blueprint
Identifier String - Blueprint to base the environment on
- blueprint
Version String - Version of the blueprint to base the environment on
- identifier String
- Unique identifier of the resource.
- inputs String
- Additional inputs for controlling the environment in YAML format
- name String
- Name of the resource.
- org
Id String - Unique identifier of the organization.
- overrides String
- Overrides for environment blueprint inputs in YAML format
- owner String
- Owner of the environment
- project
Id String - Unique identifier of the project.
- target
State String - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- based
On string - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- blueprint
Identifier string - Blueprint to base the environment on
- blueprint
Version string - Version of the blueprint to base the environment on
- identifier string
- Unique identifier of the resource.
- inputs string
- Additional inputs for controlling the environment in YAML format
- name string
- Name of the resource.
- org
Id string - Unique identifier of the organization.
- overrides string
- Overrides for environment blueprint inputs in YAML format
- owner string
- Owner of the environment
- project
Id string - Unique identifier of the project.
- target
State string - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- based_
on str - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- blueprint_
identifier str - Blueprint to base the environment on
- blueprint_
version str - Version of the blueprint to base the environment on
- identifier str
- Unique identifier of the resource.
- inputs str
- Additional inputs for controlling the environment in YAML format
- name str
- Name of the resource.
- org_
id str - Unique identifier of the organization.
- overrides str
- Overrides for environment blueprint inputs in YAML format
- owner str
- Owner of the environment
- project_
id str - Unique identifier of the project.
- target_
state str - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
- based
On String - Based on environment reference. This should be passed as \n\n.\n\n/\n\n
- blueprint
Identifier String - Blueprint to base the environment on
- blueprint
Version String - Version of the blueprint to base the environment on
- identifier String
- Unique identifier of the resource.
- inputs String
- Additional inputs for controlling the environment in YAML format
- name String
- Name of the resource.
- org
Id String - Unique identifier of the organization.
- overrides String
- Overrides for environment blueprint inputs in YAML format
- owner String
- Owner of the environment
- project
Id String - Unique identifier of the project.
- target
State String - target state of the environment. If different from the current, a pipeline will be triggered to update the environment
Import
The pulumi import command can be used, for example:
Import environment
$ pulumi import harness:platform/idpEnvironment:IdpEnvironment example <org_id>/<project_id>/<environment_id>
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
harnessTerraform Provider.
