mirror of
https://github.com/mempool/mempool.git
synced 2024-11-20 10:21:52 +01:00
20ff62779d
* Recreate a docker dir with all docker files inside and add init.sh * Add docker/README.md with example docker-compose.xml * Add mysql vars for mempool-config.json * Port can be set from env var in docker-compose.xml * Update docker-compose.xml example to use latest tag * Remove armv7 architecture from build workflow * Remove master git-hash file * Remove useless ':' in sed
19 lines
833 B
Bash
Executable File
19 lines
833 B
Bash
Executable File
#!/bin/sh
|
|
|
|
#backend
|
|
gitMaster="\.\.\/\.git\/refs\/heads\/master"
|
|
git ls-remote https://github.com/mempool/mempool.git $1 | awk '{ print $1}' > ./backend/master
|
|
cp ./docker/backend/* ./backend/
|
|
sed -i "s/${gitMaster}/master/g" ./backend/src/api/backend-info.ts
|
|
|
|
#frontend
|
|
localhostIP="127.0.0.1"
|
|
cp ./docker/frontend/* ./frontend
|
|
cp ./nginx.conf ./frontend/
|
|
cp ./nginx-mempool.conf ./frontend/
|
|
sed -i "s/${localhostIP}:80/0.0.0.0:__MEMPOOL_FRONTEND_HTTP_PORT__/g" ./frontend/nginx.conf
|
|
sed -i "s/${localhostIP}/0.0.0.0/g" ./frontend/nginx.conf
|
|
sed -i "s/user nobody;//g" ./frontend/nginx.conf
|
|
sed -i "s!/etc/nginx/nginx-mempool.conf!/etc/nginx/conf.d/nginx-mempool.conf!g" ./frontend/nginx.conf
|
|
sed -i "s/${localhostIP}:8999/__MEMPOOL_BACKEND_MAINNET_HTTP_HOST__:__MEMPOOL_BACKEND_MAINNET_HTTP_PORT__/g" ./frontend/nginx-mempool.conf
|