Custom Domain Association
Manages an App Runner Custom Domain association.
NOTE: After creation, you must use the information in the
certification_validation_records
attribute to add CNAME records to your Domain Name System (DNS). For each mapped domain name, add a mapping to the target App Runner subdomain (found in thedns_target
attribute) and one or more certificate validation records. App Runner then performs DNS validation to verify that you own or control the domain name you associated. App Runner tracks domain validity in a certificate stored in AWS Certificate Manager (ACM).
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.apprunner.CustomDomainAssociation;
import com.pulumi.aws.apprunner.CustomDomainAssociationArgs;
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 example = new CustomDomainAssociation("example", CustomDomainAssociationArgs.builder()
.domainName("example.com")
.serviceArn(aws_apprunner_service.example().arn())
.build());
}
}
Import
App Runner Custom Domain Associations can be imported by using the domain_name
and service_arn
separated by a comma (,
), e.g.,
$ pulumi import aws:apprunner/customDomainAssociation:CustomDomainAssociation example example.com,arn:aws:apprunner:us-east-1:123456789012:service/example-
app/8fe1e10304f84fd2b0df550fe98a71fa
Properties
A set of certificate CNAME records used for this domain name. See Certificate Validation Records below for more details.
Custom domain endpoint to association. Specify a base domain e.g., example.com
or a subdomain e.g., subdomain.example.com
.
Whether to associate the subdomain with the App Runner service in addition to the base domain. Defaults to true
.
ARN of the App Runner service.