Redirecting to wrong canonical address

The looks correct. I presume it looks correct to you too, so I guess we’re both surprised by the redirect from to The second server block should match the the request and return 301 to

Were there any failures during initial provisioning?

Could you SSH in to the server and…

  • check the nginx config by running sudo nginx -t
  • reload nginx by running sudo service nginx reload
  • then test the redirect again, maybe even in a different browser (Chrome caches redirects)

I’m not familiar enough with the possibilities to catalogue them, but are there any other services involved that could be responsible for the redirect (DNS settings, caching proxies, etc.)?

Edit: Maybe turn rewrite_log on and check your logs