Hey,
When I run terraform init I receive the error:
Error: Failed to query available provider packages
│
│ Could not retrieve the list of available versions for provider hashicorp/aws: could not connect to registry.terraform.io: Failed to request discovery document: Get "https://registry.terraform.io/.well-known/terraform.json": net/http: request canceled while waiting
│ for connection (Client.Timeout exceeded while awaiting headers)
I have tried to reach the site “registry.terraform.io” from my browser and everything worked fine.
But, when I tried to ping to registry.terraform.io, I received:
ping: cannot resolve registry.terraform.io: Unknown host
Something even weirder happened when I run the ping command immediately after I entered the website: registry.terraform.io. It successfully pinged! But 1 sec after it when I tried it again, it failed.