1. Packages
  2. Doppler
  3. API Docs
  4. Environment
Doppler v0.9.0 published on Tuesday, Aug 27, 2024 by Pulumiverse

doppler.Environment

Explore with Pulumi AI

doppler logo
Doppler v0.9.0 published on Tuesday, Aug 27, 2024 by Pulumiverse

    Manage a Doppler environment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as doppler from "@pulumiverse/doppler";
    
    const backendCi = new doppler.Environment("backend_ci", {
        project: "backend",
        slug: "ci",
        name: "Continuous Integration",
    });
    
    import pulumi
    import pulumiverse_doppler as doppler
    
    backend_ci = doppler.Environment("backend_ci",
        project="backend",
        slug="ci",
        name="Continuous Integration")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-doppler/sdk/go/doppler"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := doppler.NewEnvironment(ctx, "backend_ci", &doppler.EnvironmentArgs{
    			Project: pulumi.String("backend"),
    			Slug:    pulumi.String("ci"),
    			Name:    pulumi.String("Continuous Integration"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Doppler = Pulumiverse.Doppler;
    
    return await Deployment.RunAsync(() => 
    {
        var backendCi = new Doppler.Environment("backend_ci", new()
        {
            Project = "backend",
            Slug = "ci",
            Name = "Continuous Integration",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.doppler.Environment;
    import com.pulumi.doppler.EnvironmentArgs;
    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 backendCi = new Environment("backendCi", EnvironmentArgs.builder()
                .project("backend")
                .slug("ci")
                .name("Continuous Integration")
                .build());
    
        }
    }
    
    resources:
      backendCi:
        type: doppler:Environment
        name: backend_ci
        properties:
          project: backend
          slug: ci
          name: Continuous Integration
    

    Create Environment Resource

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

    Constructor syntax

    new Environment(name: string, args: EnvironmentArgs, opts?: CustomResourceOptions);
    @overload
    def Environment(resource_name: str,
                    args: EnvironmentArgs,
                    opts: Optional[ResourceOptions] = None)
    
    @overload
    def Environment(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    name: Optional[str] = None,
                    project: Optional[str] = None,
                    slug: Optional[str] = None,
                    personal_configs: Optional[bool] = None)
    func NewEnvironment(ctx *Context, name string, args EnvironmentArgs, opts ...ResourceOption) (*Environment, error)
    public Environment(string name, EnvironmentArgs args, CustomResourceOptions? opts = null)
    public Environment(String name, EnvironmentArgs args)
    public Environment(String name, EnvironmentArgs args, CustomResourceOptions options)
    
    type: doppler:Environment
    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 EnvironmentArgs
    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 EnvironmentArgs
    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 EnvironmentArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args EnvironmentArgs
    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 environmentResource = new Doppler.Environment("environmentResource", new()
    {
        Name = "string",
        Project = "string",
        Slug = "string",
        PersonalConfigs = false,
    });
    
    example, err := doppler.NewEnvironment(ctx, "environmentResource", &doppler.EnvironmentArgs{
    	Name:            pulumi.String("string"),
    	Project:         pulumi.String("string"),
    	Slug:            pulumi.String("string"),
    	PersonalConfigs: pulumi.Bool(false),
    })
    
    var environmentResource = new Environment("environmentResource", EnvironmentArgs.builder()
        .name("string")
        .project("string")
        .slug("string")
        .personalConfigs(false)
        .build());
    
    environment_resource = doppler.Environment("environmentResource",
        name="string",
        project="string",
        slug="string",
        personal_configs=False)
    
    const environmentResource = new doppler.Environment("environmentResource", {
        name: "string",
        project: "string",
        slug: "string",
        personalConfigs: false,
    });
    
    type: doppler:Environment
    properties:
        name: string
        personalConfigs: false
        project: string
        slug: string
    

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

    Name string
    The name of the Doppler environment
    Project string
    The name of the Doppler project where the environment is located
    Slug string
    The slug of the Doppler environment
    PersonalConfigs bool
    Whether or not personal configs are enabled for the environment
    Name string
    The name of the Doppler environment
    Project string
    The name of the Doppler project where the environment is located
    Slug string
    The slug of the Doppler environment
    PersonalConfigs bool
    Whether or not personal configs are enabled for the environment
    name String
    The name of the Doppler environment
    project String
    The name of the Doppler project where the environment is located
    slug String
    The slug of the Doppler environment
    personalConfigs Boolean
    Whether or not personal configs are enabled for the environment
    name string
    The name of the Doppler environment
    project string
    The name of the Doppler project where the environment is located
    slug string
    The slug of the Doppler environment
    personalConfigs boolean
    Whether or not personal configs are enabled for the environment
    name str
    The name of the Doppler environment
    project str
    The name of the Doppler project where the environment is located
    slug str
    The slug of the Doppler environment
    personal_configs bool
    Whether or not personal configs are enabled for the environment
    name String
    The name of the Doppler environment
    project String
    The name of the Doppler project where the environment is located
    slug String
    The slug of the Doppler environment
    personalConfigs Boolean
    Whether or not personal configs are enabled for the environment

    Outputs

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

    Get an existing Environment 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?: EnvironmentState, opts?: CustomResourceOptions): Environment
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            name: Optional[str] = None,
            personal_configs: Optional[bool] = None,
            project: Optional[str] = None,
            slug: Optional[str] = None) -> Environment
    func GetEnvironment(ctx *Context, name string, id IDInput, state *EnvironmentState, opts ...ResourceOption) (*Environment, error)
    public static Environment Get(string name, Input<string> id, EnvironmentState? state, CustomResourceOptions? opts = null)
    public static Environment get(String name, Output<String> id, EnvironmentState 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:
    Name string
    The name of the Doppler environment
    PersonalConfigs bool
    Whether or not personal configs are enabled for the environment
    Project string
    The name of the Doppler project where the environment is located
    Slug string
    The slug of the Doppler environment
    Name string
    The name of the Doppler environment
    PersonalConfigs bool
    Whether or not personal configs are enabled for the environment
    Project string
    The name of the Doppler project where the environment is located
    Slug string
    The slug of the Doppler environment
    name String
    The name of the Doppler environment
    personalConfigs Boolean
    Whether or not personal configs are enabled for the environment
    project String
    The name of the Doppler project where the environment is located
    slug String
    The slug of the Doppler environment
    name string
    The name of the Doppler environment
    personalConfigs boolean
    Whether or not personal configs are enabled for the environment
    project string
    The name of the Doppler project where the environment is located
    slug string
    The slug of the Doppler environment
    name str
    The name of the Doppler environment
    personal_configs bool
    Whether or not personal configs are enabled for the environment
    project str
    The name of the Doppler project where the environment is located
    slug str
    The slug of the Doppler environment
    name String
    The name of the Doppler environment
    personalConfigs Boolean
    Whether or not personal configs are enabled for the environment
    project String
    The name of the Doppler project where the environment is located
    slug String
    The slug of the Doppler environment

    Import

    $ pulumi import doppler:index/environment:Environment default <project-name>.<environment-slug>
    

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

    Package Details

    Repository
    doppler pulumiverse/pulumi-doppler
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the doppler Terraform Provider.
    doppler logo
    Doppler v0.9.0 published on Tuesday, Aug 27, 2024 by Pulumiverse