1. Packages
  2. Propelauth Provider
  3. API Docs
  4. CustomDomain
propelauth 0.4.1 published on Friday, Mar 7, 2025 by propelauth

propelauth.CustomDomain

Explore with Pulumi AI

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as propelauth from "@pulumi/propelauth";

// Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
// You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
const myCustomDomain = new propelauth.CustomDomain("myCustomDomain", {
    domain: "example.com",
    environment: "Prod",
    subdomain: "app",
});
Copy
import pulumi
import pulumi_propelauth as propelauth

# Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
# You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
my_custom_domain = propelauth.CustomDomain("myCustomDomain",
    domain="example.com",
    environment="Prod",
    subdomain="app")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/propelauth/propelauth"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		// Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
		// You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
		_, err := propelauth.NewCustomDomain(ctx, "myCustomDomain", &propelauth.CustomDomainArgs{
			Domain:      pulumi.String("example.com"),
			Environment: pulumi.String("Prod"),
			Subdomain:   pulumi.String("app"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Propelauth = Pulumi.Propelauth;

return await Deployment.RunAsync(() => 
{
    // Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
    // You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
    var myCustomDomain = new Propelauth.CustomDomain("myCustomDomain", new()
    {
        Domain = "example.com",
        Environment = "Prod",
        Subdomain = "app",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.propelauth.CustomDomain;
import com.pulumi.propelauth.CustomDomainArgs;
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) {
        // Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
        // You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
        var myCustomDomain = new CustomDomain("myCustomDomain", CustomDomainArgs.builder()
            .domain("example.com")
            .environment("Prod")
            .subdomain("app")
            .build());

    }
}
Copy
resources:
  # Initialize a custom domain with your PropelAuth environment. This does not verify the domain:
  # // You will need a DNS provider and the `propelauth_custom_domain_verification` resource to verify the domain.
  myCustomDomain:
    type: propelauth:CustomDomain
    properties:
      domain: example.com
      environment: Prod
      subdomain: app
Copy

Create CustomDomain Resource

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

Constructor syntax

new CustomDomain(name: string, args: CustomDomainArgs, opts?: CustomResourceOptions);
@overload
def CustomDomain(resource_name: str,
                 args: CustomDomainArgs,
                 opts: Optional[ResourceOptions] = None)

@overload
def CustomDomain(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 domain: Optional[str] = None,
                 environment: Optional[str] = None,
                 subdomain: Optional[str] = None)
func NewCustomDomain(ctx *Context, name string, args CustomDomainArgs, opts ...ResourceOption) (*CustomDomain, error)
public CustomDomain(string name, CustomDomainArgs args, CustomResourceOptions? opts = null)
public CustomDomain(String name, CustomDomainArgs args)
public CustomDomain(String name, CustomDomainArgs args, CustomResourceOptions options)
type: propelauth:CustomDomain
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. CustomDomainArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. CustomDomainArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. CustomDomainArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. CustomDomainArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. CustomDomainArgs
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 customDomainResource = new Propelauth.CustomDomain("customDomainResource", new()
{
    Domain = "string",
    Environment = "string",
    Subdomain = "string",
});
Copy
example, err := propelauth.NewCustomDomain(ctx, "customDomainResource", &propelauth.CustomDomainArgs{
Domain: pulumi.String("string"),
Environment: pulumi.String("string"),
Subdomain: pulumi.String("string"),
})
Copy
var customDomainResource = new CustomDomain("customDomainResource", CustomDomainArgs.builder()
    .domain("string")
    .environment("string")
    .subdomain("string")
    .build());
Copy
custom_domain_resource = propelauth.CustomDomain("customDomainResource",
    domain="string",
    environment="string",
    subdomain="string")
Copy
const customDomainResource = new propelauth.CustomDomain("customDomainResource", {
    domain: "string",
    environment: "string",
    subdomain: "string",
});
Copy
type: propelauth:CustomDomain
properties:
    domain: string
    environment: string
    subdomain: string
Copy

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

Domain This property is required. string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
Environment This property is required. string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
Subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
Domain This property is required. string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
Environment This property is required. string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
Subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
domain This property is required. String
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment This property is required. String
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain String
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
domain This property is required. string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment This property is required. string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
domain This property is required. str
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment This property is required. str
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain str
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
domain This property is required. String
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment This property is required. String
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain String
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.

Outputs

All input properties are implicitly available as output properties. Additionally, the CustomDomain resource produces the following output properties:

CnameRecordKey string
The CNAME record key for the custom domain.
CnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
CnameRecordValue string
The CNAME record value for the custom domain.
Id string
The provider-assigned unique ID for this managed resource.
TxtRecordKey string
The TXT record key for the custom domain.
TxtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
TxtRecordValue string
The TXT record value for the custom domain.
CnameRecordKey string
The CNAME record key for the custom domain.
CnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
CnameRecordValue string
The CNAME record value for the custom domain.
Id string
The provider-assigned unique ID for this managed resource.
TxtRecordKey string
The TXT record key for the custom domain.
TxtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
TxtRecordValue string
The TXT record value for the custom domain.
cnameRecordKey String
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain String
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue String
The CNAME record value for the custom domain.
id String
The provider-assigned unique ID for this managed resource.
txtRecordKey String
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain String
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue String
The TXT record value for the custom domain.
cnameRecordKey string
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue string
The CNAME record value for the custom domain.
id string
The provider-assigned unique ID for this managed resource.
txtRecordKey string
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue string
The TXT record value for the custom domain.
cname_record_key str
The CNAME record key for the custom domain.
cname_record_key_without_domain str
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cname_record_value str
The CNAME record value for the custom domain.
id str
The provider-assigned unique ID for this managed resource.
txt_record_key str
The TXT record key for the custom domain.
txt_record_key_without_domain str
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txt_record_value str
The TXT record value for the custom domain.
cnameRecordKey String
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain String
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue String
The CNAME record value for the custom domain.
id String
The provider-assigned unique ID for this managed resource.
txtRecordKey String
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain String
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue String
The TXT record value for the custom domain.

Look up Existing CustomDomain Resource

Get an existing CustomDomain 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?: CustomDomainState, opts?: CustomResourceOptions): CustomDomain
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        cname_record_key: Optional[str] = None,
        cname_record_key_without_domain: Optional[str] = None,
        cname_record_value: Optional[str] = None,
        domain: Optional[str] = None,
        environment: Optional[str] = None,
        subdomain: Optional[str] = None,
        txt_record_key: Optional[str] = None,
        txt_record_key_without_domain: Optional[str] = None,
        txt_record_value: Optional[str] = None) -> CustomDomain
func GetCustomDomain(ctx *Context, name string, id IDInput, state *CustomDomainState, opts ...ResourceOption) (*CustomDomain, error)
public static CustomDomain Get(string name, Input<string> id, CustomDomainState? state, CustomResourceOptions? opts = null)
public static CustomDomain get(String name, Output<String> id, CustomDomainState state, CustomResourceOptions options)
resources:  _:    type: propelauth:CustomDomain    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
CnameRecordKey string
The CNAME record key for the custom domain.
CnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
CnameRecordValue string
The CNAME record value for the custom domain.
Domain string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
Environment string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
Subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
TxtRecordKey string
The TXT record key for the custom domain.
TxtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
TxtRecordValue string
The TXT record value for the custom domain.
CnameRecordKey string
The CNAME record key for the custom domain.
CnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
CnameRecordValue string
The CNAME record value for the custom domain.
Domain string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
Environment string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
Subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
TxtRecordKey string
The TXT record key for the custom domain.
TxtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
TxtRecordValue string
The TXT record value for the custom domain.
cnameRecordKey String
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain String
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue String
The CNAME record value for the custom domain.
domain String
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment String
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain String
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
txtRecordKey String
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain String
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue String
The TXT record value for the custom domain.
cnameRecordKey string
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain string
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue string
The CNAME record value for the custom domain.
domain string
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment string
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain string
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
txtRecordKey string
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain string
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue string
The TXT record value for the custom domain.
cname_record_key str
The CNAME record key for the custom domain.
cname_record_key_without_domain str
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cname_record_value str
The CNAME record value for the custom domain.
domain str
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment str
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain str
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
txt_record_key str
The TXT record key for the custom domain.
txt_record_key_without_domain str
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txt_record_value str
The TXT record value for the custom domain.
cnameRecordKey String
The CNAME record key for the custom domain.
cnameRecordKeyWithoutDomain String
The CNAME record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
cnameRecordValue String
The CNAME record value for the custom domain.
domain String
The domain name for the custom domain. Your resulting auth domain will be auth.<domain>. You can also specify a subdomain like prod.example.com which will result in auth.prod.example.com
environment String
The environment for which you are configuring the custom domain. Accepted values are Staging and Prod. Note: Staging environments are only available on some pricing plans.
subdomain String
The subdomain for the custom domain. This is optional, but recommended, as it will allow PropelAuth to automatically redirect users to your application after they login. Your resulting auth domain will be auth.<subdomain>.<domain>. The value must not begin or end with a period.
txtRecordKey String
The TXT record key for the custom domain.
txtRecordKeyWithoutDomain String
The TXT record key for the custom domain without the domain (e.g. just auth instead of auth.example.com) .
txtRecordValue String
The TXT record value for the custom domain.

Import

Custom domains can be imported by which environment they are in

$ pulumi import propelauth:index/customDomain:CustomDomain example Prod
Copy

or

$ pulumi import propelauth:index/customDomain:CustomDomain example Staging
Copy

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

Package Details

Repository
propelauth propelauth/terraform-provider-propelauth
License
Notes
This Pulumi package is based on the propelauth Terraform Provider.