Skip to content

Commit 451fb58

Browse files
committed
fix: serverless url replacement bug
1 parent c4d93ab commit 451fb58

File tree

3 files changed

+404
-96
lines changed

3 files changed

+404
-96
lines changed

assets/js/local-storage.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ const defaultUrls = {};
8787
// Guard against pageParams being null/undefined and safely access nested properties
8888
if (pageParams && pageParams.influxdb_urls) {
8989
Object.entries(pageParams.influxdb_urls).forEach(([product, {providers}]) => {
90-
defaultUrls[product] = providers.filter(provider => provider.name === 'Default')[0]?.regions[0]?.url;
90+
defaultUrls[product] = providers.filter(provider => provider.name === 'Default')[0]?.regions[0]?.url || 'https://cloud2.influxdata.com';
9191
});
9292
}
9393

data/influxdb_urls.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,23 @@ cloud:
6666
- name: East US (Virginia)
6767
location: Virginia, USA
6868
url: https://eastus-1.azure.cloud2.influxdata.com
69+
70+
serverless:
71+
product: InfluxDB Cloud
72+
providers:
73+
- name: Amazon Web Services
74+
short_name: AWS
75+
iox: true
76+
regions:
77+
- name: US East (Virginia)
78+
location: Virginia, USA
79+
url: https://us-east-1-1.aws.cloud2.influxdata.com
80+
iox: true
81+
- name: EU Frankfurt
82+
location: Frankfurt, Germany
83+
url: https://eu-central-1-1.aws.cloud2.influxdata.com
84+
iox: true
85+
6986
cloud_dedicated:
7087
providers:
7188
- name: Default

0 commit comments

Comments
 (0)