GrecoTechnology / Bizbox

Bizbox project
GNU General Public License v3.0
1 stars 0 forks source link

www.domain.tld doesn't route to domain.tld for Wordpress installation #12

Open GrecoTechnology opened 1 year ago

GrecoTechnology commented 1 year ago

Describe the bug bb install command doesn't include a traefik configuration to add www.domain.tld

Additional context Fixed by manually adding the follow information

Host(`domain.tld`,`www.domain.tld`)

to both labels on the wordpress install

traefik.http.routers.sstjax-com-wordpress-http.rule
traefik.http.routers.sstjax-com-wordpress.rule

Need to add it to the ansible script

GrecoTechnology commented 1 year ago

The manual fix breaks Cloudflare DNS task with the following:

TASK [dns : Cloudflare | Add DNS Record | Add DNS Record] *************************************************************************************************************************** Thursday 07 September 2023 16:18:10 -0400 (0:00:00.273) 0:00:48.737 **** fatal: [localhost]: FAILED! => {"changed": false, "msg": "API bad request; Status: 400; Method: POST: Call: /zones/27cc306070b34a870b5ec5bed3a8457b/dns_records"}

Here is some debug information where you can see the DNS Record containing ",www" after the domain.

TASK [dns : Debug - Print Cloudflare API token] ************************************************************************************************************************************* Thursday 07 September 2023 16:18:10 -0400 (0:00:00.259) 0:00:48.464 **** [WARNING]: The value '' is not a valid IP address or network, passing this value to ipaddr filter might result in breaking change in future. ok: [localhost] => { "msg": [ "Cloudflare API Token: ee2a3eeb538596af201eb52f91ceac28bd276", "Cloudflare Email: jeremiah@grecotek.com", "DNS Zone: cuttersfamilyfarm.com", "DNS Record: cuttersfamilyfarm.com,www", "DNS Type: A", "Public IP Address: 99.27.25.115", "Is IPv4 valid: 99.27.25.115", "Is IPv6 valid: False", "DNS Proxy: False" ] }