Datasources Fix formatting for SQL data sources permissions disclaimer (#60155)

Chore: Fix formatting for sql datasources permissions disclaimer
pull/60431/head
Josh Hunt 2 years ago committed by GitHub
parent e9cf8fa751
commit 45d1cfa172
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      public/app/plugins/datasource/mssql/configuration/ConfigurationEditor.tsx
  2. 4
      public/app/plugins/datasource/mysql/configuration/ConfigurationEditor.tsx
  3. 18
      public/app/plugins/datasource/postgres/configuration/ConfigurationEditor.tsx

@ -17,6 +17,7 @@ import {
InlineFieldRow, InlineFieldRow,
InlineSwitch, InlineSwitch,
Input, Input,
Link,
SecretInput, SecretInput,
Select, Select,
useStyles2, useStyles2,
@ -270,7 +271,12 @@ export const ConfigurationEditor = (props: DataSourcePluginOptionsEditorProps<Ms
The database user should only be granted SELECT permissions on the specified database and tables you want to The database user should only be granted SELECT permissions on the specified database and tables you want to
query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example, query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example,
statements like <code>USE otherdb;</code> and <code>DROP TABLE user;</code> would be executed. To protect statements like <code>USE otherdb;</code> and <code>DROP TABLE user;</code> would be executed. To protect
against this we <em>highly</em> recommend you create a specific MS SQL user with restricted permissions. against this we <em>highly</em> recommend you create a specific MS SQL user with restricted permissions. Check
out the{' '}
<Link rel="noreferrer" target="_blank" href="http://docs.grafana.org/features/datasources/mssql/">
Microsoft SQL Server Data Source Docs
</Link>{' '}
for more information.
</Alert> </Alert>
</> </>
); );

@ -171,10 +171,10 @@ export const ConfigurationEditor = (props: DataSourcePluginOptionsEditorProps<My
query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example, query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example,
statements like <code>USE otherdb;</code> and <code>DROP TABLE user;</code> would be executed. To protect statements like <code>USE otherdb;</code> and <code>DROP TABLE user;</code> would be executed. To protect
against this we <strong>Highly</strong> recommend you create a specific MySQL user with restricted permissions. against this we <strong>Highly</strong> recommend you create a specific MySQL user with restricted permissions.
Checkout the{' '} Check out the{' '}
<Link rel="noreferrer" target="_blank" href="http://docs.grafana.org/features/datasources/mysql/"> <Link rel="noreferrer" target="_blank" href="http://docs.grafana.org/features/datasources/mysql/">
MySQL Data Source Docs MySQL Data Source Docs
</Link> </Link>{' '}
for more information. for more information.
</Alert> </Alert>
</> </>

@ -8,7 +8,17 @@ import {
updateDatasourcePluginJsonDataOption, updateDatasourcePluginJsonDataOption,
updateDatasourcePluginResetOption, updateDatasourcePluginResetOption,
} from '@grafana/data'; } from '@grafana/data';
import { Alert, InlineSwitch, FieldSet, InlineField, InlineFieldRow, Input, Select, SecretInput } from '@grafana/ui'; import {
Alert,
InlineSwitch,
FieldSet,
InlineField,
InlineFieldRow,
Input,
Select,
SecretInput,
Link,
} from '@grafana/ui';
import { ConnectionLimits } from 'app/features/plugins/sql/components/configuration/ConnectionLimits'; import { ConnectionLimits } from 'app/features/plugins/sql/components/configuration/ConnectionLimits';
import { TLSSecretsConfig } from 'app/features/plugins/sql/components/configuration/TLSSecretsConfig'; import { TLSSecretsConfig } from 'app/features/plugins/sql/components/configuration/TLSSecretsConfig';
@ -280,7 +290,11 @@ export const PostgresConfigEditor = (props: DataSourcePluginOptionsEditorProps<P
query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example, query. Grafana does not validate that queries are safe so queries can contain any SQL statement. For example,
statements like <code>DELETE FROM user;</code> and <code>DROP TABLE user;</code> would be executed. To protect statements like <code>DELETE FROM user;</code> and <code>DROP TABLE user;</code> would be executed. To protect
against this we <strong>Highly</strong> recommend you create a specific PostgreSQL user with restricted against this we <strong>Highly</strong> recommend you create a specific PostgreSQL user with restricted
permissions. permissions. Check out the{' '}
<Link rel="noreferrer" target="_blank" href="http://docs.grafana.org/features/datasources/postgres/">
PostgreSQL Data Source Docs
</Link>{' '}
for more information.
</Alert> </Alert>
</> </>
); );

Loading…
Cancel
Save