Add CDN config for space
This commit is contained in:
parent
fcb25b79ce
commit
3df0115191
@ -1,6 +1,18 @@
|
||||
resource "digitalocean_spaces_bucket" "cdn" {
|
||||
resource "digitalocean_spaces_bucket" "enp_cdn" {
|
||||
name = "en2-cdn"
|
||||
region = "nyc3"
|
||||
acl = "public-read"
|
||||
force_destroy = false
|
||||
}
|
||||
|
||||
resource "digitalocean_certificate" "enp_cdn" {
|
||||
name = "CDN"
|
||||
type = "lets_encrypt"
|
||||
domains = ["cdn.enp.one", "enp.one"]
|
||||
}
|
||||
|
||||
resource "digitalocean_cdn" "enp" {
|
||||
origin = digitalocean_spaces_bucket.enp_cdn.bucket_domain_name
|
||||
custom_domain = "cdn.enp.one"
|
||||
certificate_name = digitalocean_certificate.enp_cdn.name
|
||||
}
|
||||
|
Reference in New Issue
Block a user