Skip to content

Commit 6bc3a92

Browse files
authored
Merge pull request #386 from topcoder-platform/dev
[PROD RELEASE V6]
2 parents e3ab992 + 41f61fc commit 6bc3a92

File tree

8 files changed

+47
-12
lines changed

8 files changed

+47
-12
lines changed

.circleci/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,7 @@ workflows:
221221
- dev
222222
- TOP-2044_show-signin-modal
223223
- maintenance
224+
- review-app
224225

225226
- deployProd:
226227
context: org-global

.github/workflows/trivy.yaml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Trivy Scanner
2+
3+
permissions:
4+
contents: read
5+
security-events: write
6+
on:
7+
push:
8+
branches:
9+
- main
10+
- dev
11+
pull_request:
12+
jobs:
13+
trivy-scan:
14+
name: Use Trivy
15+
runs-on: ubuntu-24.04
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
20+
- name: Run Trivy scanner in repo mode
21+
uses: aquasecurity/[email protected]
22+
with:
23+
scan-type: "fs"
24+
ignore-unfixed: true
25+
format: "sarif"
26+
output: "trivy-results.sarif"
27+
severity: "CRITICAL,HIGH,UNKNOWN"
28+
scanners: vuln,secret,misconfig,license
29+
github-pat: ${{ secrets.GITHUB_TOKEN }}
30+
31+
- name: Upload Trivy scan results to GitHub Security tab
32+
uses: github/codeql-action/upload-sarif@v3
33+
with:
34+
sarif_file: "trivy-results.sarif"

src/lib/config/hosts.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ export const THRIVE_HOST: string = {
2323
}[HOST_ENV] || `https://www.${TC_DOMAIN}`;
2424

2525
export const APP_AUTH_CONNECTOR: string = `https://accounts-auth0.${TC_DOMAIN}`;
26-
export const ONLINE_REVIEW_HOST: string = `https://software.${TC_DOMAIN}`;
26+
export const REVIEW_APP_HOST: string = `https://review.${TC_DOMAIN}`;
2727
export const TCACADEMY_HOST: string = `https://academy.${TC_DOMAIN}`;
2828
export const SELF_SERVICE_HOST: string = `https://work.${TC_DOMAIN}`;
29-
export const TC_API_V5_HOST: string = `https://api.${TC_DOMAIN}/v5`;
29+
export const TC_API_HOST: string = `https://api.${TC_DOMAIN}/v6`;
3030
export const CONNECT_HOST: string = `https://connect.${TC_DOMAIN}`;
3131
export const WORK_MANAGER_HOST: string = `https://challenges.${TC_DOMAIN}`;
3232
export const PROFILE_HOST: string = `https://profiles.${TC_DOMAIN}`;

src/lib/config/nav-menu/all-nav-items.config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
COMMUNITY_HOST,
77
CONNECT_HOST,
88
COPILOT_PORTAL_HOST,
9-
ONLINE_REVIEW_HOST,
9+
REVIEW_APP_HOST,
1010
TALENT_SEARCH_HOST,
1111
TCACADEMY_HOST,
1212
PLATFORM_APP_HOST,
@@ -142,7 +142,7 @@ export const allNavItems: {[key: string]: NavMenuItem} = {
142142
},
143143
review: {
144144
label: 'Review',
145-
url: ONLINE_REVIEW_HOST,
145+
url: REVIEW_APP_HOST,
146146
icon: 'review',
147147
description: 'Review submissions',
148148
},

src/lib/functions/profile-nudges.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { TC_API_V5_HOST } from "lib/config";
1+
import { TC_API_HOST } from "lib/config";
22
import type { AuthUser } from "lib/app-context";
33
import { DISABLE_NUDGES, NUDGES_DISABLED_HOSTS } from "lib/config/profile-toasts.config";
44

@@ -51,7 +51,7 @@ export const fetchUserProfileCompletedness = async (user: AuthUser, force = fals
5151
// for QA purpose only
5252
const toastOverrideFlagParam = (window?.location.search.match(/[?&]+toast=(\w+)/i) ?? [])[1];
5353
const toastOverrideFlag = toastOverrideFlagParam ? `?toast=${toastOverrideFlagParam}` : '';
54-
const requestUrl: string = `${TC_API_V5_HOST}/members/${userHandle}/profileCompleteness${toastOverrideFlag}`;
54+
const requestUrl: string = `${TC_API_HOST}/members/${userHandle}/profileCompleteness${toastOverrideFlag}`;
5555
const request = fetch(requestUrl, {headers: {...getRequestAuthHeaders()}});
5656

5757
const response = await (await request).json();

src/lib/functions/support/support.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import { TC_API_V5_HOST } from 'lib/config';
1+
import { TC_API_HOST } from 'lib/config';
22
import type { ContactSupportRequest } from './contact-support-request.model'
33

44
export async function sendSupportRequest(request: ContactSupportRequest): Promise<any> {
5-
const url: string = `${TC_API_V5_HOST}/challenges/support-requests`
5+
const url: string = `${TC_API_HOST}/challenges/support-requests`
66

77
return fetch(url, {
88
method: 'POST',

src/lib/functions/user-profile.provider.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { AuthUser } from '../../main';
22
import { AUTH_USER_ROLE, AUTH_USER_ROLE_VALUES } from '../config/auth';
3-
import { TC_API_V5_HOST } from '../config';
3+
import { TC_API_HOST } from '../config';
44
import { getAuthJwtDomainProp, getRequestAuthHeaders } from './auth-jwt';
55

66
export type fetchUserProfileFn = () => AuthUser | null;
@@ -46,7 +46,7 @@ export const fetchUserProfile = async (): Promise<AuthUser> => {
4646
let resolve: (value: AuthUser) => void;
4747
localCache[userHandle] = new Promise((r) => {resolve = r});
4848

49-
const requestUrl: string = `${TC_API_V5_HOST}/members/${userHandle}`;
49+
const requestUrl: string = `${TC_API_HOST}/members/${userHandle}`;
5050
const request = fetch(requestUrl, {headers: {...getRequestAuthHeaders()}});
5151

5252
const response = await (await request).json();

types/src/lib/config/hosts.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ export declare const CHALLENGE_HOST: string;
66
export declare const COMMUNITY_HOST: string;
77
export declare const THRIVE_HOST: string;
88
export declare const APP_AUTH_CONNECTOR: string;
9-
export declare const ONLINE_REVIEW_HOST: string;
9+
export declare const REVIEW_APP_HOST: string;
1010
export declare const TCACADEMY_HOST: string;
1111
export declare const SELF_SERVICE_HOST: string;
12-
export declare const TC_API_V5_HOST: string;
12+
export declare const TC_API_HOST: string;
1313
export declare const CONNECT_HOST: string;
1414
export declare const WORK_MANAGER_HOST: string;
1515
export declare const PROFILE_HOST: string;

0 commit comments

Comments
 (0)