From 28376404a8427e3aa5ac493bf5edde83bdc98960 Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Mon, 5 Dec 2022 09:59:57 +0000 Subject: [PATCH] default to static build (#1812) --- .github/workflows/deploy.yml | 2 +- README.md | 2 ++ package.json | 5 ++--- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f389d744d..ebcac307c 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -16,7 +16,7 @@ jobs: node-version: 18 - run: npm ci - - run: npm run build:static + - run: npm run build env: NEXT_PUBLIC_INFURA_PROJECT_ID: ${{ secrets.NEXT_PUBLIC_INFURA_PROJECT_ID }} diff --git a/README.md b/README.md index 39e4dcf4d..5aefa62c9 100644 --- a/README.md +++ b/README.md @@ -351,6 +351,8 @@ npm run build npm run serve ``` +The build command runs `next export` and outputs a static site under `./out`, ready to be deployed. + ## ⬆️ Deployment Every branch or Pull Request is automatically deployed to multiple hosts for redundancy and emergency reasons: diff --git a/package.json b/package.json index e534e104c..1e92dd7d6 100644 --- a/package.json +++ b/package.json @@ -6,9 +6,8 @@ "homepage": "https://market.oceanprotocol.com", "scripts": { "start": "npm run pregenerate && next dev -p 8000", - "build": "npm run pregenerate && next build", - "build:static": "npm run build && next export", - "serve": "serve -s public/", + "build": "npm run pregenerate && next build && next export", + "serve": "serve -s out/", "pregenerate": "bash scripts/pregenerate.sh", "test": "npm run pregenerate && npm run lint && npm run type-check && npm run jest", "jest": "jest -c .jest/jest.config.js",