feat: Update sitemap host configuration
The commit updates the sitemap host to point to the production environment. This is needed so that the sitemap links will point to the correct domain, and the production environment needs to point to a specific host. The sitemap now uses the correct host url, and this is the correct config for the current state.
This commit is contained in:
parent
31a2ec373d
commit
9a35dc5563
@ -1,7 +1,5 @@
|
||||
# Set the host name for URL creation
|
||||
# host = Rails.env.production? ? "https://todayaiweather.com" : "http://127.0.0.1:3000"
|
||||
host = Rails.env.production? ? "https://pub.r2.todayaiweather.com" : "http://127.0.0.1:3000"
|
||||
# host = "https://pub.r2.todayaiweather.com"
|
||||
host = Rails.env.production? ? "https://todayaiweather.com" : "http://127.0.0.1:3000"
|
||||
Rails.application.routes.default_url_options[:host] = host
|
||||
SitemapGenerator::Sitemap.adapter = SitemapGenerator::AwsSdkAdapter.new(
|
||||
Rails.application.credentials.dig(:aws, :bucket),
|
||||
@ -11,7 +9,7 @@ SitemapGenerator::Sitemap.adapter = SitemapGenerator::AwsSdkAdapter.new(
|
||||
)
|
||||
SitemapGenerator::Sitemap.sitemaps_path = "sitemaps/"
|
||||
|
||||
SitemapGenerator::Sitemap.default_host = host
|
||||
SitemapGenerator::Sitemap.default_host = "https://pub.r2.todayaiweather.com"
|
||||
|
||||
SitemapGenerator::Sitemap.create do
|
||||
add root_path, changefreq: "daily", priority: 1.0
|
||||
|
Loading…
Reference in New Issue
Block a user