]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-17226 Display authentication-related settings in a more intuitive way
authorRevanshu Paliwal <revanshu.paliwal@sonarsource.com>
Wed, 24 Aug 2022 12:58:56 +0000 (14:58 +0200)
committersonartech <sonartech@sonarsource.com>
Thu, 25 Aug 2022 20:03:09 +0000 (20:03 +0000)
22 files changed:
server/sonar-auth-bitbucket/src/main/java/org/sonar/auth/bitbucket/BitbucketSettings.java
server/sonar-auth-github/src/main/java/org/sonar/auth/github/GitHubSettings.java
server/sonar-auth-gitlab/src/main/java/org/sonar/auth/gitlab/GitLabSettings.java
server/sonar-auth-saml/src/main/java/org/sonar/auth/saml/SamlSettings.java
server/sonar-docs/src/pages/analysis/bitbucket-cloud-integration.md
server/sonar-docs/src/pages/analysis/bitbucket-integration.md
server/sonar-docs/src/pages/analysis/github-integration.md
server/sonar-docs/src/pages/analysis/gitlab-integration.md
server/sonar-web/src/main/js/apps/settings/components/AdditionalCategories.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/AlmIntegration.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/AlmIntegrationRenderer.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/AlmTab.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/AlmTabRenderer.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/AlmIntegration-test.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/AlmIntegrationRenderer-test.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/AlmTab-test.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/AlmTabRenderer-test.tsx
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/__snapshots__/AlmIntegration-test.tsx.snap
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/__snapshots__/AlmIntegrationRenderer-test.tsx.snap
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/__snapshots__/AlmTab-test.tsx.snap
server/sonar-web/src/main/js/apps/settings/components/almIntegration/__tests__/__snapshots__/AlmTabRenderer-test.tsx.snap
sonar-core/src/main/resources/org/sonar/l10n/core.properties

index 0cc496bf99db28446819267a405e21da202449ed..29b9bdb203eaa9c07d89fdfe885699ac91529ea3 100755 (executable)
@@ -23,7 +23,6 @@ import java.util.Arrays;
 import java.util.List;
 import java.util.function.Supplier;
 import javax.annotation.CheckForNull;
-import org.sonar.api.CoreProperties;
 import org.sonar.api.PropertyType;
 import org.sonar.api.config.Configuration;
 import org.sonar.api.config.PropertyDefinition;
@@ -40,6 +39,7 @@ public class BitbucketSettings {
   public static final String WORKSPACE_ALLOWED_LIST = "sonar.auth.bitbucket.workspaces";
   public static final String DEFAULT_API_URL = "https://api.bitbucket.org/";
   public static final String DEFAULT_WEB_URL = "https://bitbucket.org/";
+  public static final String CATEGORY = "authentication";
   public static final String SUBCATEGORY = "bitbucket";
 
   private final Configuration config;
@@ -83,7 +83,7 @@ public class BitbucketSettings {
       PropertyDefinition.builder(ENABLED)
         .name("Enabled")
         .description("Enable Bitbucket users to login. Value is ignored if consumer key and secret are not defined.")
-        .category(CoreProperties.CATEGORY_ALM_INTEGRATION)
+        .category(CATEGORY)
         .subCategory(SUBCATEGORY)
         .type(PropertyType.BOOLEAN)
         .defaultValue(String.valueOf(false))
@@ -92,21 +92,21 @@ public class BitbucketSettings {
       PropertyDefinition.builder(CONSUMER_KEY)
         .name("OAuth consumer key")
         .description("Consumer key provided by Bitbucket when registering the consumer.")
-        .category(CoreProperties.CATEGORY_ALM_INTEGRATION)
+        .category(CATEGORY)
         .subCategory(SUBCATEGORY)
         .index(2)
         .build(),
       PropertyDefinition.builder(CONSUMER_SECRET)
         .name("OAuth consumer secret")
         .description("Consumer secret provided by Bitbucket when registering the consumer.")
-        .category(CoreProperties.CATEGORY_ALM_INTEGRATION)
+        .category(CATEGORY)
         .subCategory(SUBCATEGORY)
         .index(3)
         .build(),
       PropertyDefinition.builder(ALLOW_USERS_TO_SIGN_UP)
         .name("Allow users to sign-up")
         .description("Allow new users to authenticate. When set to 'false', only existing users will be able to authenticate.")
-        .category(CoreProperties.CATEGORY_ALM_INTEGRATION)
+        .category(CATEGORY)
         .subCategory(SUBCATEGORY)
         .type(PropertyType.BOOLEAN)
         .defaultValue(String.valueOf(true))
@@ -115,7 +115,7 @@ public class BitbucketSettings {
       PropertyDefinition.builder(WORKSPACE_ALLOWED_LIST)
         .name("Workspaces")
         .description("Only members of at least one of these workspace will be able to authenticate. Keep empty to disable workspace restriction. You can use either the workspace name, or the workspace slug (ex: https://bitbucket.org/{workspace-slug}).")
-        .category(CoreProperties.CATEGORY_ALM_INTEGRATION)
+        .category(CATEGORY)
         .subCategory(SUBCATEGORY)
         .multiValues(true)
         .index(5)
index 2ad356af878386d524204046b79aaa78492360c1..f95d23a2a2eabb3fe8f598939876a3c1cfbc3dbd 100644 (file)
@@ -23,7 +23,6 @@ import java.util.Arrays;
 import java.util.List;
 import javax.annotation.CheckForNull;
 import javax.annotation.Nullable;
-import org.sonar.api.CoreProperties;
 import org.sonar.api.config.Configuration;
 import org.sonar.api.config.PropertyDefinition;
 
@@ -43,7 +42,7 @@ public class GitHubSettings {
   public static final String WEB_URL = "sonar.auth.github.webUrl";
   public static final String ORGANIZATIONS = "sonar.auth.github.organizations";
 
-  private static final String CATEGORY = CoreProperties.CATEGORY_ALM_INTEGRATION;
+  private static final String CATEGORY = "authentication";
   private static final String SUBCATEGORY = "github";
 
   private final Configuration configuration;
index 65e63d406cdb96bf71a7dba98ef301b33ed9cce2..76c6905583134849917141ed51affdf958b3fd70 100644 (file)
@@ -21,7 +21,6 @@ package org.sonar.auth.gitlab;
 
 import java.util.Arrays;
 import java.util.List;
-import org.sonar.api.CoreProperties;
 import org.sonar.api.PropertyType;
 import org.sonar.api.config.Configuration;
 import org.sonar.api.config.PropertyDefinition;
@@ -39,7 +38,7 @@ public class GitLabSettings {
   public static final String GITLAB_AUTH_ALLOW_USERS_TO_SIGNUP = "sonar.auth.gitlab.allowUsersToSignUp";
   public static final String GITLAB_AUTH_SYNC_USER_GROUPS = "sonar.auth.gitlab.groupsSync";
 
-  private static final String CATEGORY = CoreProperties.CATEGORY_ALM_INTEGRATION;
+  private static final String CATEGORY = "authentication";
   private static final String SUBCATEGORY = "gitlab";
 
   private final Configuration configuration;
index e654958327a365a37de35bb95a7f91937f2ab230..4954076f41ebf275730354f0b8dab94de30168e1 100644 (file)
@@ -50,7 +50,7 @@ public class SamlSettings {
   public static final String SERVICE_PROVIDER_CERTIFICATE = "sonar.auth.saml.sp.certificate.secured";
   public static final String SERVICE_PROVIDER_PRIVATE_KEY = "sonar.auth.saml.sp.privateKey.secured";
 
-  public static final String CATEGORY = "security";
+  public static final String CATEGORY = "authentication";
   public static final String SUBCATEGORY = "saml";
 
   private final Configuration configuration;
index 39613b357212a3426be1c6d0930bb780fab518ee..74148fe21e3be6735c3444a7d728dd6c9e5fd2f9 100644 (file)
@@ -34,7 +34,7 @@ SonarQube uses a dedicated [OAuth consumer](https://support.atlassian.com/bitbuc
 - **Permissions** – Grant **Read** access for the **Pull requests** permission.
 
 ### Setting your global DevOps Platform Integration settings
-To set your global DevOps Platform Integration settings, navigate to **Administration > DevOps Platform Integrations**, select the **Bitbucket** tab, and select **Bitbucket Cloud** as the variant you want to configure. From here, specify the following settings:
+To set your global DevOps Platform Integration settings, navigate to **Administration > Configuration > General Settings > DevOps Platform Integrations**, select the **Bitbucket** tab, and select **Bitbucket Cloud** as the variant you want to configure. From here, specify the following settings:
 
 - **Configuration Name** (Enterprise and Data Center Edition only) – The name used to identify your Bitbucket Cloud configuration at the project level. Use something succinct and easily recognizable.
 - **Workspace ID** – The workspace ID is part of your bitbucket cloud URL `https://bitbucket.org/{WORKSPACE-ID}/{repository-slug}`
@@ -315,7 +315,7 @@ Create or update your OAuth consumer in your Bitbucket Cloud workspace settings
 | If you're using the same OAuth consumer for authentication and importing projects/reporting status to pull requests, make sure that the **This is a private consumer** box is checked and **Read** access for the **Pull requests** permission is granted. 
 
 ### Setting your authentication settings in SonarQube
-To set your global authentication settings, navigate to **Administration > DevOps Platform Integrations** and select the **Bitbucket** tab. Scroll down to the **Bitbucket Authentication** section and update the following settings:
+To set your global authentication settings, navigate to **Administration > Configuration > General Settings > Authentication > Bitbucket Cloud Authentication** and update the following settings:
 
 - **Enabled** - set to true.
 - **OAuth consumer key** - enter the **Key** from your OAuth consumer page in Bitbucket.
index d27ebed9c75f6220112302fe41410620a4b2ecb8..67042b104d58e9cb2683a3c64c4b994328ed4c12 100644 (file)
@@ -27,7 +27,7 @@ To set up the import of BitBucket Server repositories:
 1. Add a personal access token for importing repositories
 
 ### Setting your global DevOps Platform Integration settings
-To set your global DevOps Platform Integration settings, navigate to **Administration > DevOps Platform Integrations**, select the **Bitbucket** tab, and select **Bitbucket Server** as the variant you want to configure. From here, specify the following settings:
+To set your global DevOps Platform Integration settings, navigate to **Administration > Configuration > General Settings > DevOps Platform Integrations**, select the **Bitbucket** tab, and select **Bitbucket Server** as the variant you want to configure. From here, specify the following settings:
 
 - **Configuration Name** (Enterprise and Data Center Edition only) – The name used to identify your Bitbucket Server configuration at the project level. Use something succinct and easily recognizable.
 - **Bitbucket Server URL** – your instances URL. For example, `https://bitbucket-server.your-company.com`.
index c7bbf4a98794f1797f93f1bb27b2175041733f50..4b5eec32948c1104e069b749b4af3a9b2a673770 100644 (file)
@@ -351,7 +351,7 @@ To allow users to log in with GitHub credentials, use the GitHub App that you cr
 
 To update your global SonarQube settings:
 
-Navigate to **Administration > Configuration > General Settings > DevOps Platform Integrations > GitHub > GitHub Authentication** and update the following:
+Navigate to **Administration > Configuration > General Settings > Authentication > GitHub Authentication** and update the following:
 
 1. **Enabled** – set the switch to `true`.
 1. **Client ID** – the Client ID is found below the GitHub App ID on your GitHub App's page.
@@ -367,7 +367,7 @@ If you want to use a dedicated app for GitHub authentication, you can create a G
 
 After creating your app, update your global SonarQube settings: 
 
-Navigate to **Administration > Configuration > General Settings > DevOps Platform Integrations > GitHub > GitHub Authentication** and update the following:
+Navigate to **Administration > Configuration > General Settings > Authentication > GitHub Authentication** and update the following:
 
 1. **Enabled** – set the switch to `true`.
 1. **Client ID** – the Client ID is found below the GitHub App ID on your GitHub App's page.
index 032cd5102c0ec10646fe993d0cda09704179c23e..47fffb297afe7b7ea535e61d4bcf4c00f372adb3 100644 (file)
@@ -30,7 +30,7 @@ Specify the following settings in your OAuth app:
 - **Redirect URI** – enter your SonarQube URL with the path `/oauth2/callback/gitlab`. For example, `https://sonarqube.mycompany.com/oauth2/callback/gitlab`.
 - **Scopes** – select **api** if you plan to enable group synchronization. Select **read_user** if you only plan to delegate authentication.
 
-After saving your application, GitLab takes you to the app's page. Here you find your **Application ID** and **Secret**. Keep these handy, open your SonarQube instance, and navigate to **Administration > Configuration > General Settings > DevOps Platform Integrations > GitLab > Authentication**. Set the following settings to finish setting up GitLab authentication:
+After saving your application, GitLab takes you to the app's page. Here you find your **Application ID** and **Secret**. Keep these handy, open your SonarQube instance, and navigate to **Administration > Configuration > General Settings > Authentication > GitLab Authentication**. Set the following settings to finish setting up GitLab authentication:
 
 - **Enabled** – set to `true`.
 - **Application ID** – the Application ID is found on your GitLab app's page.
index 7b3c78f583ad4eb39ab7808ead2a3c5e169a4727..1737728d02c3643c0239e4c05e6b56839d7ee4eb 100644 (file)
@@ -82,7 +82,7 @@ export const ADDITIONAL_CATEGORIES: AdditionalCategory[] = [
     renderComponent: getAlmIntegrationComponent,
     availableGlobally: true,
     availableForProject: false,
-    displayTab: false
+    displayTab: true
   },
   {
     key: PULL_REQUEST_DECORATION_BINDING_CATEGORY,
index 127c0c1ca5b483a428a2666da937f7236be95dfe..bb471ee144e321edf53ba44771abfa5e66d19fd8 100644 (file)
@@ -34,13 +34,11 @@ import {
   AlmSettingsBindingStatusType
 } from '../../../../types/alm-settings';
 import { AppState } from '../../../../types/appstate';
-import { ExtendedSettingDefinition } from '../../../../types/settings';
 import { Dict } from '../../../../types/types';
 import AlmIntegrationRenderer from './AlmIntegrationRenderer';
 
 interface Props {
   appState: AppState;
-  definitions: ExtendedSettingDefinition[];
   location: Location;
   router: Router;
 }
@@ -212,8 +210,7 @@ export class AlmIntegration extends React.PureComponent<Props, State> {
 
   render() {
     const {
-      appState: { branchesEnabled, multipleAlmEnabled },
-      definitions: settingsDefinitions
+      appState: { branchesEnabled, multipleAlmEnabled }
     } = this.props;
     const {
       currentAlmTab,
@@ -242,7 +239,6 @@ export class AlmIntegration extends React.PureComponent<Props, State> {
         loadingAlmDefinitions={loadingAlmDefinitions}
         loadingProjectCount={loadingProjectCount}
         projectCount={projectCount}
-        settingsDefinitions={settingsDefinitions}
       />
     );
   }
index 414d9608583c5f570fe0d758697506f00422400c..769a2b2d79e6d192be1ca7673c846b3b73df06ec 100644 (file)
@@ -26,7 +26,6 @@ import {
   AlmSettingsBindingDefinitions,
   AlmSettingsBindingStatus
 } from '../../../../types/alm-settings';
-import { ExtendedSettingDefinition } from '../../../../types/settings';
 import { Dict } from '../../../../types/types';
 import { AlmTabs } from './AlmIntegration';
 import AlmTab from './AlmTab';
@@ -48,7 +47,6 @@ export interface AlmIntegrationRendererProps {
   onSelectAlmTab: (alm: AlmTabs) => void;
   onUpdateDefinitions: () => void;
   projectCount?: number;
-  settingsDefinitions: ExtendedSettingDefinition[];
 }
 
 const tabs = [
@@ -120,8 +118,7 @@ export default function AlmIntegrationRenderer(props: AlmIntegrationRendererProp
     loadingProjectCount,
     branchesEnabled,
     multipleAlmEnabled,
-    projectCount,
-    settingsDefinitions
+    projectCount
   } = props;
 
   const bindingDefinitions = {
@@ -154,7 +151,6 @@ export default function AlmIntegrationRenderer(props: AlmIntegrationRendererProp
         onCheck={props.onCheckConfiguration}
         onDelete={props.onDelete}
         onUpdateDefinitions={props.onUpdateDefinitions}
-        settingsDefinitions={settingsDefinitions}
       />
 
       {definitionKeyForDeletion && (
index a9b33a1d995170526a6d4847767df417e444e386..95c05874c1b40de86ea86ae391139b139a371e88 100644 (file)
@@ -23,7 +23,6 @@ import {
   AlmBindingDefinitionBase,
   AlmSettingsBindingStatus
 } from '../../../../types/alm-settings';
-import { ExtendedSettingDefinition } from '../../../../types/settings';
 import { Dict } from '../../../../types/types';
 import { AlmTabs } from './AlmIntegration';
 import AlmTabRenderer from './AlmTabRenderer';
@@ -39,7 +38,6 @@ interface Props {
   onCheck: (definitionKey: string) => void;
   onDelete: (definitionKey: string) => void;
   onUpdateDefinitions: () => void;
-  settingsDefinitions: ExtendedSettingDefinition[];
 }
 
 interface State {
@@ -93,8 +91,7 @@ export default class AlmTab extends React.PureComponent<Props, State> {
       definitionStatus,
       loadingAlmDefinitions,
       loadingProjectCount,
-      multipleAlmEnabled,
-      settingsDefinitions
+      multipleAlmEnabled
     } = this.props;
     const { editDefinition, editedDefinition } = this.state;
 
@@ -115,7 +112,6 @@ export default class AlmTab extends React.PureComponent<Props, State> {
         onEdit={this.handleEdit}
         onCancel={this.handleCancel}
         afterSubmit={this.handleAfterSubmit}
-        settingsDefinitions={settingsDefinitions}
       />
     );
   }
index 12482862a20f7a00e0efe5da76c35ddf099cfcb2..0ed12fa6221eff67ff1dabcf1d964a65c5fbebeb 100644 (file)
  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
  */
 import * as React from 'react';
+import { FormattedMessage } from 'react-intl';
+import { Link } from 'react-router-dom';
 import { Button } from '../../../../components/controls/buttons';
+import { Alert } from '../../../../components/ui/Alert';
 import DeferredSpinner from '../../../../components/ui/DeferredSpinner';
 import { translate } from '../../../../helpers/l10n';
 import {
@@ -28,10 +31,7 @@ import {
   AlmSettingsBindingStatus,
   isBitbucketCloudBindingDefinition
 } from '../../../../types/alm-settings';
-import { ExtendedSettingDefinition } from '../../../../types/settings';
 import { Dict } from '../../../../types/types';
-import { ALM_INTEGRATION_CATEGORY } from '../../constants';
-import CategoryDefinitionsList from '../CategoryDefinitionsList';
 import AlmBindingDefinitionBox from './AlmBindingDefinitionBox';
 import AlmBindingDefinitionForm from './AlmBindingDefinitionForm';
 import { AlmTabs } from './AlmIntegration';
@@ -53,9 +53,14 @@ export interface AlmTabRendererProps {
   onDelete: (definitionKey: string) => void;
   onEdit: (definitionKey: string) => void;
   afterSubmit: (config: AlmBindingDefinitionBase) => void;
-  settingsDefinitions: ExtendedSettingDefinition[];
 }
 
+const AUTHENTICATION_AVAILABLE_PLATFORMS = [
+  AlmKeys.GitHub,
+  AlmKeys.GitLab,
+  AlmKeys.BitbucketServer
+];
+
 export default function AlmTabRenderer(props: AlmTabRendererProps) {
   const {
     almTab,
@@ -66,8 +71,7 @@ export default function AlmTabRenderer(props: AlmTabRendererProps) {
     editedDefinition,
     loadingAlmDefinitions,
     loadingProjectCount,
-    multipleAlmEnabled,
-    settingsDefinitions
+    multipleAlmEnabled
   } = props;
 
   const preventCreation = loadingProjectCount || (!multipleAlmEnabled && definitions.length > 0);
@@ -115,16 +119,24 @@ export default function AlmTabRenderer(props: AlmTabRendererProps) {
           )}
         </DeferredSpinner>
       </div>
-
-      <div className="huge-spacer-top huge-spacer-bottom bordered-top" />
-
-      <div className="big-padded">
-        <CategoryDefinitionsList
-          category={ALM_INTEGRATION_CATEGORY}
-          definitions={settingsDefinitions}
-          subCategory={almTab}
-        />
-      </div>
+      {AUTHENTICATION_AVAILABLE_PLATFORMS.includes(almTab) && (
+        <Alert variant="info" className="spacer">
+          <FormattedMessage
+            id="settings.almintegration.tabs.authentication-moved"
+            defaultMessage={translate('settings.almintegration.tabs.authentication_moved')}
+            values={{
+              link: (
+                <Link
+                  to={{
+                    pathname: '/admin/settings?category=authentication'
+                  }}>
+                  {translate('property.category.authentication')}
+                </Link>
+              )
+            }}
+          />
+        </Alert>
+      )}
     </div>
   );
 }
index aa701feea924d6bc6f8a7c19a58a20844c465d2b..4b3fad35c2494c46abca3a6e637fae119ee2ecb5 100644 (file)
@@ -190,7 +190,6 @@ function shallowRender(props: Partial<AlmIntegration['props']> = {}) {
   return shallow<AlmIntegration>(
     <AlmIntegration
       appState={mockAppState({ branchesEnabled: true })}
-      definitions={[]}
       location={mockLocation()}
       router={mockRouter()}
       {...props}
index bb363871be3d76fb94031ed272e1c271ba863848..150027f8e3ca59b13c6281c887fb2b6af7f397b5 100644 (file)
@@ -51,7 +51,6 @@ function shallowRender(props: Partial<AlmIntegrationRendererProps> = {}) {
       onDelete={jest.fn()}
       onSelectAlmTab={jest.fn()}
       onUpdateDefinitions={jest.fn()}
-      settingsDefinitions={[]}
       {...props}
     />
   );
index 260132fa317d54a3d3b371f0c70120205971bfb0..7fbd2c73f0ccf69732c029ba1e37737666f39d00 100644 (file)
@@ -86,7 +86,6 @@ function shallowRender(props: Partial<AlmTab['props']> = {}) {
       onCheck={jest.fn()}
       onDelete={jest.fn()}
       onUpdateDefinitions={jest.fn()}
-      settingsDefinitions={[]}
       {...props}
     />
   );
index 6b55ee46e7a29b45b5ab283b9ce10f1ac7b87546..76bb366affb452d53d78f186f256241e6c354c4d 100644 (file)
@@ -104,7 +104,6 @@ function shallowRender(props: Partial<AlmTabRendererProps> = {}) {
       onDelete={jest.fn()}
       onEdit={jest.fn()}
       afterSubmit={jest.fn()}
-      settingsDefinitions={[]}
       {...props}
     />
   );
index 561988375f728f31e291c8fd80dd1e78d466ee7d..193dfaf0360d768bbfd942f1750a001248614f3c 100644 (file)
@@ -23,6 +23,5 @@ exports[`should render correctly 1`] = `
   onDelete={[Function]}
   onSelectAlmTab={[Function]}
   onUpdateDefinitions={[Function]}
-  settingsDefinitions={Array []}
 />
 `;
index 8a6aa95355abf7bfddcbc13eb9baa31d55d167c5..dbbe5ea825c945679bd8e479a4047c338aa9972b 100644 (file)
@@ -83,7 +83,6 @@ exports[`should render correctly: azure 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
 </Fragment>
 `;
@@ -171,7 +170,6 @@ exports[`should render correctly: bitbucket 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
 </Fragment>
 `;
@@ -259,7 +257,6 @@ exports[`should render correctly: default 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
 </Fragment>
 `;
@@ -347,7 +344,6 @@ exports[`should render correctly: delete modal 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
   <DeleteModal
     id="keyToDelete"
@@ -440,7 +436,6 @@ exports[`should render correctly: gitlab 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
 </Fragment>
 `;
@@ -528,7 +523,6 @@ exports[`should render correctly: loading 1`] = `
     onCheck={[MockFunction]}
     onDelete={[MockFunction]}
     onUpdateDefinitions={[MockFunction]}
-    settingsDefinitions={Array []}
   />
 </Fragment>
 `;
index 38897cfa773893c5db0f2715034807e38e3f8b02..ae9342d08d08415a6b48f6f847fe72694173a51c 100644 (file)
@@ -22,6 +22,5 @@ exports[`should render correctly 1`] = `
   onCreate={[Function]}
   onDelete={[MockFunction]}
   onEdit={[Function]}
-  settingsDefinitions={Array []}
 />
 `;
index b987913a570db98e74a508dbeaae39381cd395f1..4a8a83d00098e734d229104f76837f6b4dd84a92 100644 (file)
@@ -43,18 +43,6 @@ exports[`should render correctly for multi-ALM binding: editing a definition 1`]
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -101,18 +89,6 @@ exports[`should render correctly for multi-ALM binding: loaded 1`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -159,18 +135,6 @@ exports[`should render correctly for multi-ALM binding: loading ALM definitions
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -217,18 +181,6 @@ exports[`should render correctly for multi-ALM binding: loading project count 1`
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -275,18 +227,6 @@ exports[`should render correctly for single-ALM binding 1`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -333,18 +273,6 @@ exports[`should render correctly for single-ALM binding 2`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -391,18 +319,6 @@ exports[`should render correctly for single-ALM binding 3`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -439,18 +355,6 @@ exports[`should render correctly with validation: create a first 1`] = `
       </div>
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -501,18 +405,6 @@ exports[`should render correctly with validation: create a second 1`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -563,18 +455,6 @@ exports[`should render correctly with validation: default 1`] = `
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -611,18 +491,6 @@ exports[`should render correctly with validation: empty 1`] = `
       </div>
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
-  >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="azure"
-    />
-  </div>
 </div>
 `;
 
@@ -671,17 +539,27 @@ exports[`should render correctly with validation: pass the correct key for bitbu
       />
     </DeferredSpinner>
   </div>
-  <div
-    className="huge-spacer-top huge-spacer-bottom bordered-top"
-  />
-  <div
-    className="big-padded"
+  <Alert
+    className="spacer"
+    variant="info"
   >
-    <CategoryDefinitionsList
-      category="almintegration"
-      definitions={Array []}
-      subCategory="bitbucket"
+    <FormattedMessage
+      defaultMessage="settings.almintegration.tabs.authentication_moved"
+      id="settings.almintegration.tabs.authentication-moved"
+      values={
+        Object {
+          "link": <Link
+            to={
+              Object {
+                "pathname": "/admin/settings?category=authentication",
+              }
+            }
+          >
+            property.category.authentication
+          </Link>,
+        }
+      }
     />
-  </div>
+  </Alert>
 </div>
 `;
index 8f82d26b5419bb7ae863dabca9e22f7933d3abbe..6e857004fa2f09550871b0bb3ef677469db9cdca 100644 (file)
@@ -1250,6 +1250,7 @@ settings.almintegration.feature.alm_repo_import.description=Select repositories
 settings.almintegration.feature.alm_repo_import.disabled=Disabled
 settings.almintegration.feature.alm_repo_import.disabled.multiple=This feature is disabled because you have 2 or more integration instances configured.
 settings.almintegration.feature.alm_repo_import.disabled.no_url=This feature is disabled because your configured instance has no URL.
+settings.almintegration.tabs.authentication_moved=You can delegate authentication to this DevOps Platform. The relevant settings are under the {link} section.
 
 settings.pr_decoration.binding.category=DevOps Platform Integration
 settings.pr_decoration.binding.no_bindings=A system administrator needs to enable this feature in the global settings.
@@ -1297,17 +1298,18 @@ property.category.general.issues=Issues
 property.category.general.qualityGate=Quality Gate
 property.category.general.subProjects=Sub-projects
 property.category.almintegration=DevOps Platform Integrations
-property.category.almintegration.github=GitHub Authentication
-property.category.almintegration.github.description=In order to enable authentication on GitHub.com or GitHub Enterprise:<ul><li>SonarQube must be publicly accessible through HTTPS only</li><li>The property 'sonar.core.serverBaseURL' must be set to this public HTTPS URL</li><li>In your GitHub profile, you need to create a Developer Application for which the 'Authorization callback URL' must be set to <code>'&lt;value_of_sonar.core.serverBaseURL_property&gt;/oauth2/callback'</code>.</li></ul>
-property.category.almintegration.gitlab=GitLab Authentication
-property.category.almintegration.gitlab.description=In order to enable GitLab authentication, the property 'sonar.core.serverBaseURL' must be set to the public URL
-property.category.almintegration.bitbucket=Bitbucket Cloud Authentication
-property.category.almintegration.bitbucket.description=In order to enable authentication on Bitbucket.org: <ul><li>SonarQube must be publicly accessible through HTTPS only</li><li>The property 'sonar.core.serverBaseURL' must be set to this public HTTPS URL</li><li>In your Bitbucket OAuth Consumer settings, 'Callback URL' must be set to <code>'&lt;value_of_sonar.core.serverBaseURL_property&gt;'</code>.</li></ul>
+property.category.authentication=Authentication
+property.category.authentication.github=GitHub Authentication
+property.category.authentication.github.description=In order to enable authentication on GitHub.com or GitHub Enterprise:<ul><li>SonarQube must be publicly accessible through HTTPS only</li><li>The property 'sonar.core.serverBaseURL' must be set to this public HTTPS URL</li><li>In your GitHub profile, you need to create a Developer Application for which the 'Authorization callback URL' must be set to <code>'&lt;value_of_sonar.core.serverBaseURL_property&gt;/oauth2/callback'</code>.</li></ul>
+property.category.authentication.gitlab=GitLab Authentication
+property.category.authentication.gitlab.description=In order to enable GitLab authentication, the property 'sonar.core.serverBaseURL' must be set to the public URL
+property.category.authentication.bitbucket=Bitbucket Cloud Authentication
+property.category.authentication.bitbucket.description=In order to enable authentication on Bitbucket.org: <ul><li>SonarQube must be publicly accessible through HTTPS only</li><li>The property 'sonar.core.serverBaseURL' must be set to this public HTTPS URL</li><li>In your Bitbucket OAuth Consumer settings, 'Callback URL' must be set to <code>'&lt;value_of_sonar.core.serverBaseURL_property&gt;'</code>.</li></ul>
+property.category.authentication.saml=SAML
+property.category.authentication.saml.description=In order to enable SAML authentication, the property 'sonar.core.serverBaseURL' must be set to the public URL
 property.category.organizations=Organizations
 property.category.security=Security
 property.category.security.encryption=Encryption
-property.category.security.saml=SAML
-property.category.security.saml.description=In order to enable SAML authentication, the property 'sonar.core.serverBaseURL' must be set to the public URL
 property.category.java=Java
 property.category.differentialViews=New Code
 property.category.codeCoverage=Code Coverage