work from Lenny and Beamer for Chainquery/Lbrycrd
This commit is contained in:
parent
81b9613208
commit
c30c2d3840
7 changed files with 17 additions and 23 deletions
5
.gitignore
vendored
5
.gitignore
vendored
|
@ -1,4 +1,7 @@
|
|||
.gitlab-ci.yml
|
||||
.DS_Store
|
||||
*/docker-compose.override.yml
|
||||
docker-compose.yml
|
||||
*/data/
|
||||
|
||||
./docker-compose.yml
|
||||
*.zip
|
|
@ -1,4 +1,5 @@
|
|||
data/
|
||||
data.z*
|
||||
chainquery.z*
|
||||
*.zip
|
||||
compile/
|
||||
|
|
|
@ -10,7 +10,7 @@ DEBUGMODE=false
|
|||
## Mysql Creds ##
|
||||
#################
|
||||
MYSQL_SERVER=10.5.1.10
|
||||
MYSQL_USER=chainquery
|
||||
MYSQL_USER=root
|
||||
MYSQL_PASSWORD=changeme
|
||||
MYSQL_DATABASE=chainquery
|
||||
MYSQL_ROOT_PASSWORD=changeme
|
||||
|
|
1
chainquery/.gitignore
vendored
1
chainquery/.gitignore
vendored
|
@ -1,3 +1,4 @@
|
|||
data/
|
||||
data.z*
|
||||
chainquery.z*
|
||||
*.zip
|
||||
|
|
|
@ -1,16 +0,0 @@
|
|||
## TODO: Don't hardcode this stuff for production
|
||||
|
||||
#Debug mode outputs specific information to the console
|
||||
debugmode=false
|
||||
|
||||
#LBRYcrd URL is required for chainquery to query the blockchain
|
||||
lbrycrdurl="rpc://lbryrpc:changeme@10.6.1.2:9245"
|
||||
|
||||
#MySQL DSN is required for chainquery to store information.
|
||||
mysqldsn="changeme:changeme@tcp(10.6.1.10:3306)/chainquery"
|
||||
|
||||
#API MySQL DSN is required for chainquery to expose a SQL query service
|
||||
apimysqldsn="changeme:changeme@tcp(10.6.1.10:3306)/chainquery"
|
||||
|
||||
#The command that should be executed to trigger a self update of the software. For linux, for example, `<yourscript>.sh`
|
||||
#DEFAULT-autoupdatecommand=[unset]
|
|
@ -18,6 +18,8 @@ services:
|
|||
- "traefik.expose=false"
|
||||
environment:
|
||||
RUN_MODE: chainquery
|
||||
env_file:
|
||||
- .env
|
||||
expose:
|
||||
- 9245
|
||||
- 9246
|
||||
|
|
|
@ -19,19 +19,22 @@ rm -f /var/run/lbrycrd.pid
|
|||
|
||||
## Set config params
|
||||
## TODO: Make this more automagic in the future.
|
||||
echo "rpcuser=lbryrpc\nrpcpassword=$RPC_PASSWORD" > /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcuser=$RPC_USER" > /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcpassword=$RPC_PASSWORD" >> /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcallowip=$RPC_ALLOW_IP" >> /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcuser=$RPC_USER" >> /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcport=9245" >> /data/.lbrycrd/lbrycrd.conf
|
||||
echo "rpcbind=0.0.0.0" >> /data/.lbrycrd/lbrycrd.conf
|
||||
#echo "bind=0.0.0.0" >> /data/.lbrycrd/lbrycrd.conf
|
||||
|
||||
## Control this invocation through envvar.
|
||||
case $RUN_MODE in
|
||||
default )
|
||||
su -c "lbrycrdd -server -conf=/data/.lbrycrd/ -printtoconsole" lbrycrd
|
||||
su -c "lbrycrdd -server -conf=/data/.lbrycrd/lbrycrd.conf -printtoconsole" lbrycrd
|
||||
;;
|
||||
reindex )
|
||||
su -c "lbrycrdd -server -txindex -reindex -conf=/data/.lbrycrd/ -printtoconsole" lbrycrd
|
||||
su -c "lbrycrdd -server -txindex -reindex -conf=/data/.lbrycrd/lbrycrd.conf -printtoconsole" lbrycrd
|
||||
;;
|
||||
chainquery )
|
||||
su -c "lbrycrdd -server -txindex -conf=/data/.lbrycrd/ -printtoconsole" lbrycrd
|
||||
su -c "lbrycrdd -server -txindex -conf=/data/.lbrycrd/lbrycrd.conf -printtoconsole" lbrycrd
|
||||
;;
|
||||
esac
|
||||
|
|
Loading…
Reference in a new issue