Skip to content

Commit

Permalink
Set NODE_ENV to production for build steps in workflows
Browse files Browse the repository at this point in the history
This ensures that builds for both the server and client use the production environment, aligning with best practices and preventing unintended behavior during builds. Updated scripts in GitHub Actions workflows for test-server and test-client.
  • Loading branch information
SquirrelDevelopper committed Dec 24, 2024
1 parent bb34c74 commit 12e3845
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,13 @@ jobs:
run: npm ci
- name: Build
working-directory: ./shared-lib
run: npm run build --if-present
run: NODE_ENV=production npm run build --if-present
- name: Install
working-directory: ./client
run: npm ci
- name: Build
working-directory: ./client
run: npm run build --if-present
run: NODE_ENV=production npm run build --if-present
- name: Test
working-directory: ./client
run: npm test
4 changes: 2 additions & 2 deletions .github/workflows/test-server.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,13 @@ jobs:
run: npm ci
- name: Build
working-directory: ./shared-lib
run: npm run build --if-present
run: NODE_ENV=production npm run build --if-present
- name: Install
working-directory: ./server
run: npm ci
- name: Build
working-directory: ./server
run: npm run build --if-present
run: NODE_ENV=production npm run build --if-present
- name: Test
working-directory: ./server
run: npm test
Expand Down

0 comments on commit 12e3845

Please sign in to comment.