Mastodon Terraform - Fastly Service for Mastodon Application File Hosting
Terraform module for creating a service in Fastly for directing traffic towards an external S3-style bucket for hosting mastodon media files (for example, files.mastodon.social).
No modules.
Name
Description
Type
Default
Required
app_hostname
Hostname of the mastodon app that this service belongs to.
string
n/a
yes
backend_address
Address to use for connecting to the backend. Can be a hostname or an IP address.
string
n/a
yes
backend_name
Optional name for the backend.
string
""
no
backend_ssl_check
Be strict about checking SSL certs when connecting to the backend.
bool
true
no
bucket_name
Name of the exoscale bucket this service will point to. Default is 'app_hostname' with dashes instead of periods.
string
""
no
datadog
Whether to send logging info to Datadog
bool
false
no
datadog_region
The region that log data will be sent to.
string
"EU"
no
datadog_service
Datadog service name to use for logs
string
"fastly"
no
datadog_token
API key from Datadog.
string
""
no
force_tls_hsts
Force TLS and HTTP Strict Transport Security (HSTS) to ensure that every request is secure.
bool
true
no
hostname
Hostname the service points to.
string
n/a
yes
hsts_duration
Number of seconds for the client to remember only to use HTTPS.
number
31557600
no
name
Name of the fastly service (defaults to hostname).
string
""
no
product_enablement
Which additional Fastly products to enable for this service.
object({ brotli_compression = optional(bool, false) domain_inspector = optional(bool, false) image_optimizer = optional(bool, false) origin_inspector = optional(bool, false) websockets = optional(bool, false) })
{ "brotli_compression": false, "domain_inspector": false, "image_optimizer": false, "origin_inspector": false, "websockets": false }
no
shield_region
Which Fastly shield region to use. Should correspond with the shield code.
string
n/a
yes
ssl_hostname
Hostname to use for SSL verification (if different from 'hostname').
string
""
no
tls_authority
Which certificate authority to use for the certificates
string
"certainly"
no
tls_domains
Custom domains to use for a TLS subscription. Defaults to a combination of 'hostname' and 'domains'
list(string)
[]
no
tls_enable
Whether to create a TLS subscription in Fastly for the domain(s)
bool
false
no
Name
Description
active_version
The currently active version of the Fastly Service
cloned_version
The latest cloned version by the provider
id
The ID of this resource