Skip to content

Commit

Permalink
Update redirects in netlify.toml for root domains with 301 status
Browse files Browse the repository at this point in the history
  • Loading branch information
shawnthompson committed Jan 21, 2025
1 parent a8d82b6 commit c73cb6e
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,20 @@
[functions]
directory = "netlify/functions"

# Redirect root domain to language-specific directories
# Redirect root of aaact.canada.ca to /en/
[[redirects]]
from = "https://aaact.canada.ca/*"
to = "/en/:splat"
status = 200
from = "https://aaact.canada.ca/"
to = "/en/"
status = 301
force = true

# Redirect root of aatia.canada.ca to /fr/
[[redirects]]
from = "https://aatia.canada.ca/*"
to = "/fr/:splat"
status = 200
from = "https://aatia.canada.ca/"
to = "/fr/"
status = 301
force = true

# Exclude static assets from redirects
[[redirects]]
from = "/css/*"
to = "/css/:splat"
status = 200

# Opt-in to the Netlify Lighthouse plugin (choose one):

Expand Down

0 comments on commit c73cb6e

Please sign in to comment.