eeg_nest/.cpanel.yml

34 lines
892 B
YAML
Raw Normal View History

2023-05-09 15:39:39 +00:00
---
deployment:
tasks:
- export DEPLOY_PATH=/home4/educa7ls/staging.eegsac.com
# Install dependencies
- pnpm i --frozen-lockfile
# Build Nestjs
- pnpm build
# Build JSX files
- node ./esbuild-prod.js
# Build hydration script
- node ./esbuild-client-prod.js
# Build tailwind
- ./node_modules/.bin/tailwindcss -i static/tailwind.css -o ./static/styles.css --minify
# Remove previous deployments
- rm -rf $DEPLOY_PATH/*
# Move files to deploy path
- /bin/cp -r ./dist $DEPLOY_PATH
- /bin/cp -r ./static $DEPLOY_PATH
- /bin/cp ./package.json $DEPLOY_PATH
- /bin/cp ./pnpm-lock.yaml $DEPLOY_PATH
- /bin/cp ./.htaccess $DEPLOY_PATH
# Remove build dependencies
- rm -rf ./node_modules
# Install prod deps
- cd $DEPLOY_PATH
- pnpm i --frozen-lockfile --prod
# Success??