Browse Source

switched to var and port 55555 internally

master
reid 3 years ago
parent
commit
9c4420a8ff
  1. 3
      docker-compose.yaml
  2. 8
      rpc/mainnet-start.sh
  3. 2
      rpc/server.js

3
docker-compose.yaml

@ -6,7 +6,7 @@ services:
restart: on-failure restart: on-failure
stop_grace_period: 1m stop_grace_period: 1m
ports: ports:
- 55555:50002 - 55555:55555
- 9091:9090 - 9091:9090
environment: environment:
ELECTRUM_IP: $ELECTRUM_IP ELECTRUM_IP: $ELECTRUM_IP
@ -16,3 +16,4 @@ services:
BITCOIN_RPC_USER: $BITCOIN_RPC_USER BITCOIN_RPC_USER: $BITCOIN_RPC_USER
BITCOIN_RPC_PASS: $BITCOIN_RPC_PASS BITCOIN_RPC_PASS: $BITCOIN_RPC_PASS
BITCOIN_RPC_AUTH: $BITCOIN_RPC_AUTH BITCOIN_RPC_AUTH: $BITCOIN_RPC_AUTH
INTERNAL_IP: $INTERNAL_IP

8
rpc/mainnet-start.sh

@ -6,19 +6,19 @@ echo Running modified mainnet script...
# docker-compose.yml passes the folllowing env vars: # docker-compose.yml passes the folllowing env vars:
# $BITCOIN_RPC_AUTH, $BITCOIN_PORT, $BITCOIN_IP, $BITCOIN_PORT, # $BITCOIN_RPC_AUTH, $BITCOIN_PORT, $BITCOIN_IP, $BITCOIN_PORT,
# $ELECTRUM_IP, and $ELECTRUM_PORT # $ELECTRUM_IP, and $ELECTRUM_PORT
export PROXY_PORT=50002 export PROXY_PORT=55555
export BITCOIN_RPC_PORT=$BITCOIN_RPC_PORT export BITCOIN_RPC_PORT=$BITCOIN_RPC_PORT
export BITCOIN_IP=$BITCOIN_IP export BITCOIN_IP=$BITCOIN_IP
export ELECTRUM_IP=$ELECTRUM_IP export ELECTRUM_IP=$ELECTRUM_IP
export ELECTRUM_PORT=$ELECTRUM_PORT export ELECTRUM_PORT=$ELECTRUM_PORT
export BITCOIN_RPC_AUTH=$BITCOIN_RPC_AUTH export BITCOIN_RPC_AUTH=$BITCOIN_RPC_AUTH
export BITCOIN_RPC_PASS=$BITCOIN_RPC_PASS export BITCOIN_RPC_PASS=$BITCOIN_RPC_PASS
export APP_URBIT_IP=$APP_URBIT_IP export INTERNAL_IP=$INTERNAL_IP
if [ -z "${APP_URBIT_IP}" ] if [ -z "${INTERNAL_IP}" ]
then then
cp index.html /index/index.html cp index.html /index/index.html
sed -i "s/local.ip.address.here/${APP_URBIT_IP}/g" /index/index.html sed -i "s/local.ip.address.here/${INTERNAL_IP}/g" /index/index.html
fi fi
nginx -c /etc/nginx/conf.d/nginx.conf nginx -c /etc/nginx/conf.d/nginx.conf

2
rpc/server.js

@ -29,7 +29,7 @@ const network =
: bitcoin.networks.bitcoin; : bitcoin.networks.bitcoin;
const app = express(); const app = express();
const port = 50002; const port = 55555;
app.use(express.json()); app.use(express.json());
const identity = (x) => x; const identity = (x) => x;

Loading…
Cancel
Save