// *** 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/domain:Domain")]
public partial class Domain : global::Pulumi.CustomResource
{
///
/// Application this domain routes to.
///
[Output("applicationId")]
public Output ApplicationId { get; private set; } = null!;
///
/// How TLS certificates are obtained. Use `Letsencrypt` for automatic certificates. Valid values: `Letsencrypt`, `None`, `Custom`.
///
[Output("certificateType")]
public Output CertificateType { get; private set; } = null!;
///
/// Compose stack this domain routes to.
///
[Output("composeId")]
public Output ComposeId { get; private set; } = null!;
///
/// RFC 3339 timestamp of when the domain was created.
///
[Output("createdAt")]
public Output CreatedAt { get; private set; } = null!;
///
/// Traefik certificate resolver name, when `CertificateType` is `Custom`.
///
[Output("customCertResolver")]
public Output CustomCertResolver { get; private set; } = null!;
///
/// Traefik entrypoint to bind, when not using the defaults.
///
[Output("customEntrypoint")]
public Output CustomEntrypoint { get; private set; } = null!;
///
/// What kind of target this domain points at. Valid values: `Compose`, `Application`, `Preview`.
///
[Output("domainType")]
public Output DomainType { get; private set; } = null!;
///
/// Protect this domain with Dokploy's forward auth.
///
[Output("forwardAuthEnabled")]
public Output ForwardAuthEnabled { get; private set; } = null!;
///
/// Fully-qualified hostname, for example `api.example.com`.
///
[Output("host")]
public Output Host { get; private set; } = null!;
///
/// Serve the domain over HTTPS and redirect HTTP traffic to it.
///
[Output("https")]
public Output Https { get; private set; } = null!;
///
/// Path the request is rewritten to before it reaches the container, defaults to `/`.
///
[Output("internalPath")]
public Output InternalPath { get; private set; } = null!;
///
/// Names of Traefik middlewares to apply.
///
[Output("middlewares")]
public Output> Middlewares { get; private set; } = null!;
///
/// Path prefix this domain routes, defaults to `/`.
///
[Output("path")]
public Output Path { get; private set; } = null!;
///
/// Container port that receives the traffic, defaults to `3000`.
///
[Output("port")]
public Output Port { get; private set; } = null!;
///
/// Preview deployment this domain routes to.
///
[Output("previewDeploymentId")]
public Output PreviewDeploymentId { get; private set; } = null!;
///
/// Name of the service inside a Compose stack that receives the traffic. Required when `ComposeId` is set.
///
[Output("serviceName")]
public Output ServiceName { get; private set; } = null!;
///
/// Strip `Path` from the request before forwarding it.
///
[Output("stripPath")]
public Output StripPath { get; private set; } = null!;
///
/// Create a Domain 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 Domain(string name, DomainArgs args, CustomResourceOptions? options = null)
: base("dokploy:index/domain:Domain", name, args ?? new DomainArgs(), MakeResourceOptions(options, ""))
{
}
private Domain(string name, Input id, DomainState? state = null, CustomResourceOptions? options = null)
: base("dokploy:index/domain:Domain", 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}",
};
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 Domain 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 Domain Get(string name, Input id, DomainState? state = null, CustomResourceOptions? options = null)
{
return new Domain(name, id, state, options);
}
}
public sealed class DomainArgs : global::Pulumi.ResourceArgs
{
///
/// Application this domain routes to.
///
[Input("applicationId")]
public Input? ApplicationId { get; set; }
///
/// How TLS certificates are obtained. Use `Letsencrypt` for automatic certificates. Valid values: `Letsencrypt`, `None`, `Custom`.
///
[Input("certificateType")]
public Input? CertificateType { get; set; }
///
/// Compose stack this domain routes to.
///
[Input("composeId")]
public Input? ComposeId { get; set; }
///
/// Traefik certificate resolver name, when `CertificateType` is `Custom`.
///
[Input("customCertResolver")]
public Input? CustomCertResolver { get; set; }
///
/// Traefik entrypoint to bind, when not using the defaults.
///
[Input("customEntrypoint")]
public Input? CustomEntrypoint { get; set; }
///
/// What kind of target this domain points at. Valid values: `Compose`, `Application`, `Preview`.
///
[Input("domainType")]
public Input? DomainType { get; set; }
///
/// Protect this domain with Dokploy's forward auth.
///
[Input("forwardAuthEnabled")]
public Input? ForwardAuthEnabled { get; set; }
///
/// Fully-qualified hostname, for example `api.example.com`.
///
[Input("host", required: true)]
public Input Host { get; set; } = null!;
///
/// Serve the domain over HTTPS and redirect HTTP traffic to it.
///
[Input("https")]
public Input? Https { get; set; }
///
/// Path the request is rewritten to before it reaches the container, defaults to `/`.
///
[Input("internalPath")]
public Input? InternalPath { get; set; }
[Input("middlewares")]
private InputList? _middlewares;
///
/// Names of Traefik middlewares to apply.
///
public InputList Middlewares
{
get => _middlewares ?? (_middlewares = new InputList());
set => _middlewares = value;
}
///
/// Path prefix this domain routes, defaults to `/`.
///
[Input("path")]
public Input? Path { get; set; }
///
/// Container port that receives the traffic, defaults to `3000`.
///
[Input("port")]
public Input? Port { get; set; }
///
/// Preview deployment this domain routes to.
///
[Input("previewDeploymentId")]
public Input? PreviewDeploymentId { get; set; }
///
/// Name of the service inside a Compose stack that receives the traffic. Required when `ComposeId` is set.
///
[Input("serviceName")]
public Input? ServiceName { get; set; }
///
/// Strip `Path` from the request before forwarding it.
///
[Input("stripPath")]
public Input? StripPath { get; set; }
public DomainArgs()
{
}
public static new DomainArgs Empty => new DomainArgs();
}
public sealed class DomainState : global::Pulumi.ResourceArgs
{
///
/// Application this domain routes to.
///
[Input("applicationId")]
public Input? ApplicationId { get; set; }
///
/// How TLS certificates are obtained. Use `Letsencrypt` for automatic certificates. Valid values: `Letsencrypt`, `None`, `Custom`.
///
[Input("certificateType")]
public Input? CertificateType { get; set; }
///
/// Compose stack this domain routes to.
///
[Input("composeId")]
public Input? ComposeId { get; set; }
///
/// RFC 3339 timestamp of when the domain was created.
///
[Input("createdAt")]
public Input? CreatedAt { get; set; }
///
/// Traefik certificate resolver name, when `CertificateType` is `Custom`.
///
[Input("customCertResolver")]
public Input? CustomCertResolver { get; set; }
///
/// Traefik entrypoint to bind, when not using the defaults.
///
[Input("customEntrypoint")]
public Input? CustomEntrypoint { get; set; }
///
/// What kind of target this domain points at. Valid values: `Compose`, `Application`, `Preview`.
///
[Input("domainType")]
public Input? DomainType { get; set; }
///
/// Protect this domain with Dokploy's forward auth.
///
[Input("forwardAuthEnabled")]
public Input? ForwardAuthEnabled { get; set; }
///
/// Fully-qualified hostname, for example `api.example.com`.
///
[Input("host")]
public Input? Host { get; set; }
///
/// Serve the domain over HTTPS and redirect HTTP traffic to it.
///
[Input("https")]
public Input? Https { get; set; }
///
/// Path the request is rewritten to before it reaches the container, defaults to `/`.
///
[Input("internalPath")]
public Input? InternalPath { get; set; }
[Input("middlewares")]
private InputList? _middlewares;
///
/// Names of Traefik middlewares to apply.
///
public InputList Middlewares
{
get => _middlewares ?? (_middlewares = new InputList());
set => _middlewares = value;
}
///
/// Path prefix this domain routes, defaults to `/`.
///
[Input("path")]
public Input? Path { get; set; }
///
/// Container port that receives the traffic, defaults to `3000`.
///
[Input("port")]
public Input? Port { get; set; }
///
/// Preview deployment this domain routes to.
///
[Input("previewDeploymentId")]
public Input? PreviewDeploymentId { get; set; }
///
/// Name of the service inside a Compose stack that receives the traffic. Required when `ComposeId` is set.
///
[Input("serviceName")]
public Input? ServiceName { get; set; }
///
/// Strip `Path` from the request before forwarding it.
///
[Input("stripPath")]
public Input? StripPath { get; set; }
public DomainState()
{
}
public static new DomainState Empty => new DomainState();
}
}