// *** WARNING: this file was generated by pulumi-language-dotnet. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;
using Pulumi;
namespace Maxvojtkov.Dokploy
{
[DokployResourceType("dokploy:index/environment:Environment")]
public partial class Environment : global::Pulumi.CustomResource
{
///
/// RFC 3339 timestamp of when the environment was created.
///
[Output("createdAt")]
public Output CreatedAt { get; private set; } = null!;
///
/// Free-form description.
///
[Output("description")]
public Output Description { get; private set; } = null!;
///
/// Environment-wide variables in `KEY=value` format, one per line. These are merged into every service in this environment.
///
[Output("env")]
public Output Env { get; private set; } = null!;
///
/// Whether this is the project's default environment.
///
[Output("isDefault")]
public Output IsDefault { get; private set; } = null!;
///
/// Environment name, for example `Staging`.
///
[Output("name")]
public Output Name { get; private set; } = null!;
///
/// Project this environment belongs to.
///
[Output("projectId")]
public Output ProjectId { get; private set; } = null!;
///
/// Create a Environment resource with the given unique name, arguments, and options.
///
///
/// The unique name of the resource
/// The arguments used to populate this resource's properties
/// A bag of options that control this resource's behavior
public Environment(string name, EnvironmentArgs args, CustomResourceOptions? options = null)
: base("dokploy:index/environment:Environment", name, args ?? new EnvironmentArgs(), MakeResourceOptions(options, ""))
{
}
private Environment(string name, Input id, EnvironmentState? state = null, CustomResourceOptions? options = null)
: base("dokploy:index/environment:Environment", name, state, MakeResourceOptions(options, id))
{
}
private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input? id)
{
var defaultOptions = new CustomResourceOptions
{
Version = Utilities.Version,
PluginDownloadURL = "github://api.github.com/maxvojtkov/pulumi-dokploy",
};
var merged = CustomResourceOptions.Merge(defaultOptions, options);
// Override the ID if one was specified for consistency with other language SDKs.
merged.Id = id ?? merged.Id;
return merged;
}
///
/// Get an existing Environment resource's state with the given name, ID, and optional extra
/// properties used to qualify the lookup.
///
///
/// The unique name of the resulting resource.
/// The unique provider ID of the resource to lookup.
/// Any extra arguments used during the lookup.
/// A bag of options that control this resource's behavior
public static Environment Get(string name, Input id, EnvironmentState? state = null, CustomResourceOptions? options = null)
{
return new Environment(name, id, state, options);
}
}
public sealed class EnvironmentArgs : global::Pulumi.ResourceArgs
{
///
/// Free-form description.
///
[Input("description")]
public Input? Description { get; set; }
///
/// Environment-wide variables in `KEY=value` format, one per line. These are merged into every service in this environment.
///
[Input("env")]
public Input? Env { get; set; }
///
/// Environment name, for example `Staging`.
///
[Input("name")]
public Input? Name { get; set; }
///
/// Project this environment belongs to.
///
[Input("projectId", required: true)]
public Input ProjectId { get; set; } = null!;
public EnvironmentArgs()
{
}
public static new EnvironmentArgs Empty => new EnvironmentArgs();
}
public sealed class EnvironmentState : global::Pulumi.ResourceArgs
{
///
/// RFC 3339 timestamp of when the environment was created.
///
[Input("createdAt")]
public Input? CreatedAt { get; set; }
///
/// Free-form description.
///
[Input("description")]
public Input? Description { get; set; }
///
/// Environment-wide variables in `KEY=value` format, one per line. These are merged into every service in this environment.
///
[Input("env")]
public Input? Env { get; set; }
///
/// Whether this is the project's default environment.
///
[Input("isDefault")]
public Input? IsDefault { get; set; }
///
/// Environment name, for example `Staging`.
///
[Input("name")]
public Input? Name { get; set; }
///
/// Project this environment belongs to.
///
[Input("projectId")]
public Input? ProjectId { get; set; }
public EnvironmentState()
{
}
public static new EnvironmentState Empty => new EnvironmentState();
}
}