mirror of
https://github.com/roleypoly/roleypoly.git
synced 2025-04-25 03:49:11 +00:00
20 lines
No EOL
580 B
HCL
20 lines
No EOL
580 B
HCL
resource "tls_private_key" "tls_pk" {
|
|
algorithm = "RSA"
|
|
}
|
|
|
|
resource "tls_cert_request" "web_csr" {
|
|
key_algorithm = tls_private_key.tls_pk.algorithm
|
|
private_key_pem = tls_private_key.tls_pk.private_key_pem
|
|
|
|
subject {
|
|
common_name = "web-${var.environment_tag}.roleypoly.com"
|
|
organization = "Roleypoly"
|
|
}
|
|
}
|
|
|
|
resource "cloudflare_origin_ca_certificate" "web" {
|
|
csr = tls_cert_request.web_csr.cert_request_pem
|
|
hostnames = ["web-${var.environment_tag}.roleypoly.com"]
|
|
request_type = "origin-rsa"
|
|
requested_validity = 365 * 15
|
|
} |