Skip to content

Commit

Permalink
Update deploy workflow to fix url issue
Browse files Browse the repository at this point in the history
  • Loading branch information
phoenixpereira committed May 28, 2024
1 parent f1e14ef commit fcadcf6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ jobs:
${{ runner.os }}-nextjs-${{ hashFiles('**/pnpm-lock.yaml', '**/yarn.lock', '**/package-lock.json') }}-
- name: Install dependencies
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
- name: Set PUBLIC_URL environment variable
run: echo "PUBLIC_URL=/MGT-Detection-UI" >> $GITHUB_ENV
- name: Build with Next.js
run: ${{ steps.detect-package-manager.outputs.runner }} next build
- name: Upload artifact
Expand Down
4 changes: 3 additions & 1 deletion src/components/Statistics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ const Statistics: React.FunctionComponent<StatisticsProps> = ({ userText }) => {
useEffect(() => {
const fetchData = async () => {
try {
const response = await fetch(`${process.env.PUBLIC_URL}/combined_analysis.json`);
const response = await fetch(
`${process.env.PUBLIC_URL}/combined_analysis.json`,
);
const data = await response.json();

setHumanData({
Expand Down

0 comments on commit fcadcf6

Please sign in to comment.