Wizard: Compliance URL via suffix
This switches from a full path to a partial one, making the compliance url work properly in local dev environment.
This commit is contained in:
parent
cd5daade6b
commit
3740c53375
2 changed files with 4 additions and 12 deletions
|
|
@ -14,8 +14,7 @@ import { Oscap, removeBetaFromRelease } from './Oscap';
|
|||
|
||||
import {
|
||||
COMPLIANCE_AND_VULN_SCANNING_URL,
|
||||
COMPLIANCE_PROD_URL,
|
||||
COMPLIANCE_STAGE_URL,
|
||||
COMPLIANCE_URL,
|
||||
} from '../../../../constants';
|
||||
import { useBackendPrefetch } from '../../../../store/backendApi';
|
||||
import { useAppDispatch, useAppSelector } from '../../../../store/hooks';
|
||||
|
|
@ -34,10 +33,7 @@ import {
|
|||
selectComplianceType,
|
||||
clearKernelAppend,
|
||||
} from '../../../../store/wizardSlice';
|
||||
import {
|
||||
useFlag,
|
||||
useGetEnvironment,
|
||||
} from '../../../../Utilities/useGetEnvironment';
|
||||
import { useFlag } from '../../../../Utilities/useGetEnvironment';
|
||||
|
||||
const OscapStep = () => {
|
||||
const dispatch = useAppDispatch();
|
||||
|
|
@ -45,7 +41,6 @@ const OscapStep = () => {
|
|||
const complianceType = useAppSelector(selectComplianceType);
|
||||
const profileID = useAppSelector(selectComplianceProfileID);
|
||||
const prefetchOscapProfile = useBackendPrefetch('getOscapProfiles', {});
|
||||
const { isProd } = useGetEnvironment();
|
||||
const release = removeBetaFromRelease(useAppSelector(selectDistribution));
|
||||
const { data: currentProfileData } = useGetOscapCustomizationsQuery(
|
||||
{
|
||||
|
|
@ -139,7 +134,7 @@ const OscapStep = () => {
|
|||
icon={<ExternalLinkAltIcon />}
|
||||
iconPosition="right"
|
||||
isInline
|
||||
href={isProd() ? COMPLIANCE_PROD_URL : COMPLIANCE_STAGE_URL}
|
||||
href={COMPLIANCE_URL}
|
||||
>
|
||||
Define new policies in Insights Compliance
|
||||
</Button>
|
||||
|
|
|
|||
|
|
@ -24,10 +24,7 @@ export const RELEASE_LIFECYCLE_URL =
|
|||
'https://access.redhat.com/support/policy/updates/errata';
|
||||
export const AZURE_AUTH_URL =
|
||||
'https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow';
|
||||
export const COMPLIANCE_PROD_URL =
|
||||
'https://console.redhat.com/insights/compliance/scappolicies';
|
||||
export const COMPLIANCE_STAGE_URL =
|
||||
'https://console.stage.redhat.com/insights/compliance/scappolicies';
|
||||
export const COMPLIANCE_URL = '/insights/compliance/scappolicies';
|
||||
export const ACTIVATION_KEYS_URL = '/insights/connector/activation-keys';
|
||||
export const COMPLIANCE_AND_VULN_SCANNING_URL =
|
||||
'https://docs.redhat.com/en/documentation/red_hat_enterprise_linux/6/html/security_guide/chap-compliance_and_vulnerability_scanning';
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue