aws-static-website.Website
Explore with Pulumi AI
Create Website Resource
new Website(name: string, args: WebsiteArgs, opts?: CustomResourceOptions);
@overload
def Website(resource_name: str,
opts: Optional[ResourceOptions] = None,
add_website_version_header: Optional[bool] = None,
atomic_deployments: Optional[bool] = None,
cache_ttl: Optional[float] = None,
cdn_args: Optional[CDNArgsArgs] = None,
certificate_arn: Optional[str] = None,
error404: Optional[str] = None,
index_html: Optional[str] = None,
price_class: Optional[str] = None,
site_path: Optional[str] = None,
subdomain: Optional[str] = None,
target_domain: Optional[str] = None,
with_cdn: Optional[bool] = None,
with_logs: Optional[bool] = None)
@overload
def Website(resource_name: str,
args: WebsiteArgs,
opts: Optional[ResourceOptions] = None)
func NewWebsite(ctx *Context, name string, args WebsiteArgs, opts ...ResourceOption) (*Website, error)
public Website(string name, WebsiteArgs args, CustomResourceOptions? opts = null)
public Website(String name, WebsiteArgs args)
public Website(String name, WebsiteArgs args, CustomResourceOptions options)
type: aws-static-website:Website
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args WebsiteArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args WebsiteArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args WebsiteArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args WebsiteArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args WebsiteArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Website Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The Website resource accepts the following input properties:
- Site
Path string The root directory containing the website's contents.
- Add
Website boolVersion Header Enable a cache control header to be attached to every request from an Cloudfront Function.
- Atomic
Deployments bool Provision a new bucket on each deployment.
- Cache
TTL double TTL in seconds for cached objects.
- Cdn
Args Pulumi.Aws Static Website. Inputs. CDNArgs Args Optional arguments used to configure the CDN.
- Certificate
ARN string The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- Error404 string
default 404 page
- Index
HTML string The default document for the site. Defaults to index.html
- Price
Class string The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- Subdomain string
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- Target
Domain string The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- With
CDN bool Provision CloudFront CDN to serve content.
- With
Logs bool Provision a bucket to hold access logs.
- Site
Path string The root directory containing the website's contents.
- Add
Website boolVersion Header Enable a cache control header to be attached to every request from an Cloudfront Function.
- Atomic
Deployments bool Provision a new bucket on each deployment.
- Cache
TTL float64 TTL in seconds for cached objects.
- Cdn
Args CDNArgsArgs Optional arguments used to configure the CDN.
- Certificate
ARN string The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- Error404 string
default 404 page
- Index
HTML string The default document for the site. Defaults to index.html
- Price
Class string The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- Subdomain string
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- Target
Domain string The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- With
CDN bool Provision CloudFront CDN to serve content.
- With
Logs bool Provision a bucket to hold access logs.
- site
Path String The root directory containing the website's contents.
- add
Website BooleanVersion Header Enable a cache control header to be attached to every request from an Cloudfront Function.
- atomic
Deployments Boolean Provision a new bucket on each deployment.
- cache
TTL Double TTL in seconds for cached objects.
- cdn
Args CDNArgsArgs Optional arguments used to configure the CDN.
- certificate
ARN String The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- error404 String
default 404 page
- index
HTML String The default document for the site. Defaults to index.html
- price
Class String The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- subdomain String
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- target
Domain String The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- with
CDN Boolean Provision CloudFront CDN to serve content.
- with
Logs Boolean Provision a bucket to hold access logs.
- site
Path string The root directory containing the website's contents.
- add
Website booleanVersion Header Enable a cache control header to be attached to every request from an Cloudfront Function.
- atomic
Deployments boolean Provision a new bucket on each deployment.
- cache
TTL number TTL in seconds for cached objects.
- cdn
Args CDNArgsArgs Optional arguments used to configure the CDN.
- certificate
ARN string The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- error404 string
default 404 page
- index
HTML string The default document for the site. Defaults to index.html
- price
Class string The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- subdomain string
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- target
Domain string The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- with
CDN boolean Provision CloudFront CDN to serve content.
- with
Logs boolean Provision a bucket to hold access logs.
- site_
path str The root directory containing the website's contents.
- add_
website_ boolversion_ header Enable a cache control header to be attached to every request from an Cloudfront Function.
- atomic_
deployments bool Provision a new bucket on each deployment.
- cache_
ttl float TTL in seconds for cached objects.
- cdn_
args CDNArgsArgs Optional arguments used to configure the CDN.
- certificate_
arn str The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- error404 str
default 404 page
- index_
html str The default document for the site. Defaults to index.html
- price_
class str The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- subdomain str
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- target_
domain str The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- with_
cdn bool Provision CloudFront CDN to serve content.
- with_
logs bool Provision a bucket to hold access logs.
- site
Path String The root directory containing the website's contents.
- add
Website BooleanVersion Header Enable a cache control header to be attached to every request from an Cloudfront Function.
- atomic
Deployments Boolean Provision a new bucket on each deployment.
- cache
TTL Number TTL in seconds for cached objects.
- cdn
Args Property Map Optional arguments used to configure the CDN.
- certificate
ARN String The ARN of the ACM certificate to use for serving HTTPS. If one is not provided, a certificate will be created during the provisioning process.
- error404 String
default 404 page
- index
HTML String The default document for the site. Defaults to index.html
- price
Class String The price class to use for the CloudFront configuration. Defaults to 100 if not specified. Valid values are
all
,100
, and200
- subdomain String
An optional subdomain that can be used to serve the content. This can typically be used to provision a www alias or if a deeply nested subdomain is needed (e.g. foo.bar.baz.com).
- target
Domain String The domain used to serve the content. A Route53 hosted zone must exist for this domain.
- with
CDN Boolean Provision CloudFront CDN to serve content.
- with
Logs Boolean Provision a bucket to hold access logs.
Outputs
All input properties are implicitly available as output properties. Additionally, the Website resource produces the following output properties:
- Bucket
Name string The name of the s3 bucket containing the website contents.
- Bucket
Website stringURL The website URL for the s3 bucket.
- Website
URL string The URL to access the website
- Cdn
Domain stringName The domain name for the CDN.
- Cdn
URL string The URL for the CDN
- Logs
Bucket stringName The name of the s3 bucket containing the access logs.
- Bucket
Name string The name of the s3 bucket containing the website contents.
- Bucket
Website stringURL The website URL for the s3 bucket.
- Website
URL string The URL to access the website
- Cdn
Domain stringName The domain name for the CDN.
- Cdn
URL string The URL for the CDN
- Logs
Bucket stringName The name of the s3 bucket containing the access logs.
- bucket
Name String The name of the s3 bucket containing the website contents.
- bucket
Website StringURL The website URL for the s3 bucket.
- website
URL String The URL to access the website
- cdn
Domain StringName The domain name for the CDN.
- cdn
URL String The URL for the CDN
- logs
Bucket StringName The name of the s3 bucket containing the access logs.
- bucket
Name string The name of the s3 bucket containing the website contents.
- bucket
Website stringURL The website URL for the s3 bucket.
- website
URL string The URL to access the website
- cdn
Domain stringName The domain name for the CDN.
- cdn
URL string The URL for the CDN
- logs
Bucket stringName The name of the s3 bucket containing the access logs.
- bucket_
name str The name of the s3 bucket containing the website contents.
- bucket_
website_ strurl The website URL for the s3 bucket.
- website_
url str The URL to access the website
- cdn_
domain_ strname The domain name for the CDN.
- cdn_
url str The URL for the CDN
- logs_
bucket_ strname The name of the s3 bucket containing the access logs.
- bucket
Name String The name of the s3 bucket containing the website contents.
- bucket
Website StringURL The website URL for the s3 bucket.
- website
URL String The URL to access the website
- cdn
Domain StringName The domain name for the CDN.
- cdn
URL String The URL for the CDN
- logs
Bucket StringName The name of the s3 bucket containing the access logs.
Supporting Types
CDNArgs
- Cloudfront
Function List<Pulumi.Associations Aws. Cloud Front. Inputs. Distribution Ordered Cache Behavior Function Association> A config block that triggers a cloudfront function with specific actions.
- Forwarded
Values Pulumi.Aws. Cloud Front. Inputs. Distribution Default Cache Behavior Forwarded Values The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- Lambda
Function List<Pulumi.Associations Aws. Cloud Front. Inputs. Distribution Ordered Cache Behavior Lambda Function Association> A config block that triggers a lambda function with specific actions.
- Cloudfront
Function DistributionAssociations Ordered Cache Behavior Function Association A config block that triggers a cloudfront function with specific actions.
- Forwarded
Values DistributionDefault Cache Behavior Forwarded Values The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- Lambda
Function DistributionAssociations Ordered Cache Behavior Lambda Function Association A config block that triggers a lambda function with specific actions.
- cloudfront
Function List<DistributionAssociations Ordered Cache Behavior Function Association> A config block that triggers a cloudfront function with specific actions.
- forwarded
Values DistributionDefault Cache Behavior Forwarded Values The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- lambda
Function List<DistributionAssociations Ordered Cache Behavior Lambda Function Association> A config block that triggers a lambda function with specific actions.
- cloudfront
Function pulumiAssociations Awstypesinputcloudfront Distribution Ordered Cache Behavior Function Association[] A config block that triggers a cloudfront function with specific actions.
- forwarded
Values pulumiAwstypesinputcloudfront Distribution Default Cache Behavior Forwarded Values The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- lambda
Function pulumiAssociations Awstypesinputcloudfront Distribution Ordered Cache Behavior Lambda Function Association[] A config block that triggers a lambda function with specific actions.
- cloudfront_
function_ Distributionassociations Ordered Cache Behavior Function Association Args] A config block that triggers a cloudfront function with specific actions.
- forwarded_
values DistributionDefault Cache Behavior Forwarded Values Args The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- lambda_
function_ Distributionassociations Ordered Cache Behavior Lambda Function Association Args] A config block that triggers a lambda function with specific actions.
- cloudfront
Function List<Property Map>Associations A config block that triggers a cloudfront function with specific actions.
- forwarded
Values Property Map The forwarded values configuration that specifies how CloudFront handles query strings, cookies and headers.
- lambda
Function List<Property Map>Associations A config block that triggers a lambda function with specific actions.
Package Details
- Repository
- aws-static-website pulumi/pulumi-aws-static-website
- License