File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -21,13 +21,16 @@ jobs:
2121
2222 - name : Create .env.production file
2323 run : |
24+ echo "NODE_ENV=production" > .env.production
2425 echo "MODE=production" > .env.production
2526 echo "VITE_GA_MEASUREMENT_ID=${{ secrets.VITE_GA_MEASUREMENT_ID }}" >> .env.production
2627
2728 - name : Install dependencies
2829 run : npm ci
2930
3031 - name : Run build
32+ env :
33+ NODE_ENV : production
3134 run : npm run build -- --mode production
3235
3336 - name : Verify Build Mode
3740 - name : Debug .env.production file
3841 run : cat .env.production || echo ".env.production not found"
3942
43+ - name : Verify Build Mode in Output Files
44+ run : grep -r "import.meta.env" dist/ || echo "No env variables found in built files"
45+
4046 - name : Docker build & push
4147 run : |
4248 docker login -u ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_PASSWORD }}
You can’t perform that action at this time.
0 commit comments