certificate not being issued

Hello,
I have issued a certificate for my app to use a custom domain:

Hostname                  = www.<app-name>.com
DNS Provider              = cloudflare
Certificate Authority     = Let's Encrypt
Issued                    = 
Added to App              = 4 minutes ago
Source                    = fly

I left it running for two days and it was not issued. I have since removed it and retried as seen above. I have managed to successfully issue a certificate for just <app-name>.com. However, I did have to add and remove it a few times before it was successfully issued nearly straight away - after leaving about a day between each add/remove.

It seems (for me) to be a bit of luck whether the certificate is issued so a bit of clarification on the process would be great (or if somebody else is having the same issue).

as mentioned in this forum post it may be related to the port 443 not being configured. i have configured this and my fly.toml file looks like:

[build]

[deploy]
  release_command = "python manage.py migrate --noinput"

[env]
  PORT = "8000"

[http_service]
  internal_port = 8000
  force_https = true
  auto_stop_machines = true
  auto_start_machines = true
  min_machines_running = 0
  processes = ["app"]

[[services]]
  http_checks = []
  internal_port = 8000
  processes = ["app"]
  protocol = "tcp"
  script_checks = []

  [[services.ports]]
    handlers = ["tls", "http"]
    port = 443

[[vm]]
  cpu_kind = "shared"
  cpus = 1
  memory_mb = 1024

[[statics]]
  guest_path = "/code/static"
  url_prefix = "/static/"

but the certificate is still not being issued.

I resolved this issue by reverted to the original fly.toml:

[build]

[deploy]
  release_command = "python manage.py migrate --noinput"

[env]
  PORT = "8000"

[http_service]
  internal_port = 8000
  force_https = true
  auto_stop_machines = true
  auto_start_machines = true
  min_machines_running = 0
  processes = ["app"]

[[vm]]
  cpu_kind = "shared"
  cpus = 1
  memory_mb = 1024

[[statics]]
  guest_path = "/code/static"
  url_prefix = "/static/"

turns out my issue was spotted in a comment by @tomasztomczyk in this related forum post here.
The dns settings were being proxied through Cloudflare, I changed the @ and www records to DNS Only.
i.e. from:
Screenshot 2023-12-27 at 21.35.12
to:
Screenshot 2023-12-27 at 21.35.35
and the certificate seemed to issue immediately as expected.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.