Skip to content

Commit c81218a

Browse files
authoredMar 20, 2024
Update clouds and bump version (grafana#133)
* Add nightly dependency and remove as * Bump version * Remove unnecessary type and use import
1 parent 8262190 commit c81218a

File tree

3 files changed

+695
-39
lines changed

3 files changed

+695
-39
lines changed
 

‎package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@grafana/azure-sdk",
3-
"version": "0.0.1",
3+
"version": "0.0.2",
44
"description": "Common Azure features for Grafana",
55
"main": "dist/index.js",
66
"module": "dist/esm/index.js",
@@ -32,7 +32,7 @@
3232
"devDependencies": {
3333
"@grafana/data": "10.2.3",
3434
"@grafana/eslint-config": "^7.0.0",
35-
"@grafana/runtime": "10.2.3",
35+
"@grafana/runtime": "nightly",
3636
"@grafana/tsconfig": "^1.3.0-rc1",
3737
"@grafana/ui": "10.2.3",
3838
"@rollup/plugin-commonjs": "25.0.7",

‎src/clouds.ts

+9-17
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,22 @@
1-
import { AzureSettings, config } from '@grafana/runtime';
2-
3-
// TODO: Remove when the list of clouds added directly to @grafana/runtime
4-
// https://github.com/grafana/grafana/pull/84039
5-
interface AzureSettings2 extends AzureSettings {
6-
clouds?: AzureCloudInfo[];
7-
}
8-
9-
export interface AzureCloudInfo {
10-
name: string;
11-
displayName: string;
12-
}
1+
import { AzureCloudInfo, config } from '@grafana/runtime';
132

143
const predefinedClouds: AzureCloudInfo[] = [
154
{
16-
name: 'AzureCloud', displayName: 'Azure'
5+
name: 'AzureCloud',
6+
displayName: 'Azure',
177
},
188
{
19-
name: 'AzureChinaCloud', displayName: 'Azure China'
9+
name: 'AzureChinaCloud',
10+
displayName: 'Azure China',
2011
},
2112
{
22-
name: 'AzureUSGovernment', displayName: 'Azure US Government'
23-
}
13+
name: 'AzureUSGovernment',
14+
displayName: 'Azure US Government',
15+
},
2416
];
2517

2618
export function getAzureClouds(): AzureCloudInfo[] {
27-
const settingsEx = (config.azure as unknown as AzureSettings2);
19+
const settingsEx = config.azure;
2820

2921
// Return list of clouds from Grafana configuration if they are provided
3022
if (Array.isArray(settingsEx.clouds)) {

‎yarn.lock

+684-20
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)
Please sign in to comment.