// *** 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
{
///
/// An external secret manager Dokploy resolves environment variables from at deploy time.
///
/// Reference a secret from any `Env` value with `${{vault.<scope>.<key>}}`. The value is fetched when the deployment runs and is never stored in Dokploy — so rotating it in the vault takes effect on the next deploy with no Terraform change.
///
/// Supported `providerType` values: `Hashicorp` (Vault/OpenBao), `Infisical`, `Aws` (Secrets Manager), `Doppler`, `Azure` (Key Vault) and `Scaleway`.
///
[DokployResourceType("dokploy:index/vaultProvider:VaultProvider")]
public partial class VaultProvider : global::Pulumi.CustomResource
{
///
/// JSON array scoping which projects or environments may resolve secrets from this provider. Pass `jsonencode([])` to leave it unscoped.
///
[Output("assignments")]
public Output Assignments { get; private set; } = null!;
///
/// Provider credentials as a JSON object, including the `providerType` discriminator.
///
[Output("config")]
public Output Config { get; private set; } = null!;
///
/// RFC 3339 timestamp of when the connection was created.
///
[Output("createdAt")]
public Output CreatedAt { get; private set; } = null!;
///
/// Name of the connection, unique within the organization.
///
[Output("name")]
public Output Name { get; private set; } = null!;
///
/// Organization that owns the connection.
///
[Output("organizationId")]
public Output OrganizationId { get; private set; } = null!;
///
/// Provider kind derived from `Config`.
///
[Output("providerType")]
public Output ProviderType { get; private set; } = null!;
///
/// Create a VaultProvider 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 VaultProvider(string name, VaultProviderArgs args, CustomResourceOptions? options = null)
: base("dokploy:index/vaultProvider:VaultProvider", name, args ?? new VaultProviderArgs(), MakeResourceOptions(options, ""))
{
}
private VaultProvider(string name, Input id, VaultProviderState? state = null, CustomResourceOptions? options = null)
: base("dokploy:index/vaultProvider:VaultProvider", name, state, MakeResourceOptions(options, id))
{
}
private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input? id)
{
var defaultOptions = new CustomResourceOptions
{
Version = Utilities.Version,
PluginDownloadURL = "https://gitea.coolify.vojtkov.dev/usr_unknown/pulumi-dokploy/releases/download/v${VERSION}",
AdditionalSecretOutputs =
{
"config",
},
};
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 VaultProvider 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 VaultProvider Get(string name, Input id, VaultProviderState? state = null, CustomResourceOptions? options = null)
{
return new VaultProvider(name, id, state, options);
}
}
public sealed class VaultProviderArgs : global::Pulumi.ResourceArgs
{
///
/// JSON array scoping which projects or environments may resolve secrets from this provider. Pass `jsonencode([])` to leave it unscoped.
///
[Input("assignments", required: true)]
public Input Assignments { get; set; } = null!;
[Input("config", required: true)]
private Input? _config;
///
/// Provider credentials as a JSON object, including the `providerType` discriminator.
///
public Input? Config
{
get => _config;
set
{
var emptySecret = Output.CreateSecret(0);
_config = Output.Tuple?, int>(value, emptySecret).Apply(t => t.Item1);
}
}
///
/// Name of the connection, unique within the organization.
///
[Input("name")]
public Input? Name { get; set; }
public VaultProviderArgs()
{
}
public static new VaultProviderArgs Empty => new VaultProviderArgs();
}
public sealed class VaultProviderState : global::Pulumi.ResourceArgs
{
///
/// JSON array scoping which projects or environments may resolve secrets from this provider. Pass `jsonencode([])` to leave it unscoped.
///
[Input("assignments")]
public Input? Assignments { get; set; }
[Input("config")]
private Input? _config;
///
/// Provider credentials as a JSON object, including the `providerType` discriminator.
///
public Input? Config
{
get => _config;
set
{
var emptySecret = Output.CreateSecret(0);
_config = Output.Tuple?, int>(value, emptySecret).Apply(t => t.Item1);
}
}
///
/// RFC 3339 timestamp of when the connection was created.
///
[Input("createdAt")]
public Input? CreatedAt { get; set; }
///
/// Name of the connection, unique within the organization.
///
[Input("name")]
public Input? Name { get; set; }
///
/// Organization that owns the connection.
///
[Input("organizationId")]
public Input? OrganizationId { get; set; }
///
/// Provider kind derived from `Config`.
///
[Input("providerType")]
public Input? ProviderType { get; set; }
public VaultProviderState()
{
}
public static new VaultProviderState Empty => new VaultProviderState();
}
}