mirror of
https://github.com/mempool/mempool.git
synced 2025-03-03 17:47:01 +01:00
Minor tweaks to production, use git pull --rebase, only build 1 frontend
This commit is contained in:
parent
81d05e23b8
commit
7f7c6ef6f8
3 changed files with 18 additions and 9 deletions
|
@ -3,12 +3,19 @@ for site in mainnet liquid testnet bisq
|
||||||
do
|
do
|
||||||
git clone https://github.com/mempool/mempool "${HOME}/${site}"
|
git clone https://github.com/mempool/mempool "${HOME}/${site}"
|
||||||
mkdir -p "${HOME}/public_html/${site}/"
|
mkdir -p "${HOME}/public_html/${site}/"
|
||||||
|
|
||||||
cd "${HOME}/${site}/backend/"
|
cd "${HOME}/${site}/backend/"
|
||||||
cp "../production/mempool-config.${site}.json" "mempool-config.json"
|
cp "../production/mempool-config.${site}.json" "mempool-config.json"
|
||||||
touch cache.json
|
touch cache.json
|
||||||
|
|
||||||
npm install
|
npm install
|
||||||
npm run build
|
npm run build
|
||||||
cd "${HOME}/${site}/frontend/"
|
|
||||||
npm install
|
if [ "${site}" = "mainnet" ]
|
||||||
npm run build
|
then
|
||||||
|
cd "${HOME}/${site}/frontend/"
|
||||||
|
npm install
|
||||||
|
npm run build
|
||||||
|
rsync -av ./dist/mempool/* "${HOME}/public_html/${site}/"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
|
|
2
production/mempool-kill-all
Normal file
2
production/mempool-kill-all
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
#!/usr/bin/env zsh
|
||||||
|
killall sh node
|
|
@ -7,21 +7,21 @@ touch $HOME/lock
|
||||||
echo 'rebuilding mempool sites'|wall
|
echo 'rebuilding mempool sites'|wall
|
||||||
|
|
||||||
cd "$HOME/mempool"
|
cd "$HOME/mempool"
|
||||||
git pull origin master
|
git pull --rebase origin master
|
||||||
cd "$HOME/"
|
cd "$HOME/"
|
||||||
|
|
||||||
for site in mainnet liquid testnet bisq
|
for site in mainnet liquid testnet bisq
|
||||||
do
|
do
|
||||||
cd "$HOME/${site}"
|
cd "$HOME/${site}"
|
||||||
git pull origin master
|
git pull --rebase origin master
|
||||||
hash=$(git rev-parse HEAD)
|
hash=$(git rev-parse HEAD)
|
||||||
|
|
||||||
if [ "${site}" = "mainnet" ]
|
if [ "${site}" = "mainnet" ]
|
||||||
then
|
then
|
||||||
cd "$HOME/${site}/frontend"
|
cd "$HOME/${site}/frontend"
|
||||||
npm install
|
npm install
|
||||||
npm run build
|
npm run build
|
||||||
rsync -av ./dist/mempool/* "${HOME}/public_html/${site}/"
|
rsync -av ./dist/mempool/* "${HOME}/public_html/${site}/"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd "$HOME/${site}/backend"
|
cd "$HOME/${site}/backend"
|
||||||
|
|
Loading…
Add table
Reference in a new issue