Fix client build

This commit is contained in:
Adrian Wozniak 2020-05-01 23:52:27 +02:00
parent ee95dcd916
commit 1b035eb7c5
2 changed files with 7 additions and 4 deletions

View File

@ -7,12 +7,12 @@ sources:
- https://git.sr.ht/~tsumanu/jirs - https://git.sr.ht/~tsumanu/jirs
environment: environment:
deploy: adrian.wozniak@ita-prog.pl deploy: adrian.wozniak@ita-prog.pl
NODE_ENV: production
DEBUG: false DEBUG: false
JIRS_CLIENT_PORT: 80 JIRS_CLIENT_PORT: 80
JIRS_CLIENT_BIND: jirs.ita-prog.pl JIRS_CLIENT_BIND: jirs.ita-prog.pl
JIRS_SERVER_PORT: 80 JIRS_SERVER_PORT: 80
JIRS_SERVER_BIND: jirs.ita-prog.pl JIRS_SERVER_BIND: jirs.ita-prog.pl
CI: true
secrets: secrets:
- 7ebab768-e5e4-4c9d-ba57-ec41a72c5665 - 7ebab768-e5e4-4c9d-ba57-ec41a72c5665
tasks: tasks:
@ -22,12 +22,15 @@ tasks:
curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sudo sh curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sudo sh
- test: | - test: |
cd ~/jirs/jirs-client cd ~/jirs/jirs-client
export NODE_ENV=development
wasm-pack test --node wasm-pack test --node
- build: | - build: |
cd ~/jirs/jirs-client cd ~/jirs/jirs-client
NODE_ENV=development yarn export NODE_ENV=development
yarn
yarn global add webpack-cli yarn global add webpack-cli
yarn add webpack-cli yarn add webpack-cli
export NODE_ENV=production
yarn webpack-cli -p --config ./webpack.config.js yarn webpack-cli -p --config ./webpack.config.js
- deploy: | - deploy: |
cd ~/jirs cd ~/jirs

View File

@ -11,9 +11,9 @@ secrets:
tasks: tasks:
- build_config: | - build_config: |
cd jirs/jirs-server cd jirs/jirs-server
cp ~/jirs/.builds/db.toml ~/jirs/jirs-server/db.toml cp ../.builds/db.toml ./
- setup: | - setup: |
1 sudo systemctl start postgresql || journalctl -xe
rustup toolchain install nightly rustup toolchain install nightly
rustup default nightly rustup default nightly
cargo install diesel_cli --no-default-features --features postgres cargo install diesel_cli --no-default-features --features postgres