Jump to content

Search the Community

Showing results for tags 'docker'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • News & Announcements
    • BlockForums Announcements
    • Denarius Announcements
  • Cryptocurrency Discussions
    • Cryptocurrencies
    • Altcoin Announcements
    • General Discussion
    • Tutorials & Help
  • Denarius Discussions
    • General Discussion
    • Tutorials & Help
    • Marketing & PR
    • Development
    • Mining & Staking
    • Trading & Exchanges
    • Marketplace
  • Programming & Design
    • Development QA
    • Design QA
  • Gaming
    • Bot Downloads & Discussion
    • Gaming Discussion
  • Classifieds
    • Buy Sell and Trade
  • Other Discussions
    • The Lounge
    • Hardware & IoT
    • Tutorials & Guides
    • Domains & Hosting

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me


BTC Address

Found 9 results

  1. About time to break out the Raspberry Pi4 4gb again and play around in docker with docker-compose. Install Docker curl -sSL https://get.docker.com | sh Change permissions for your user account, probably pi sudo usermod -aG docker pi reboot or logout so you don't have to sudo for docker commands and then test that worked docker run hello-world Now install docker-compose sudo apt-get install -y libffi-dev libssl-dev sudo apt-get install -y python3 python3-pip sudo apt-get remove python-configparser sudo pip3 install docker-compose Test docker-compose worked docker-compose
  2. This is relatively easy and I am going to setup a clean Ubuntu 18.04 VM to show how I am doing this. The idea is how to grab any stats we want and throw them into a pretty Grafana dashboard, and I think grabbing coingecko API is a great example of how to walkthrough the whole process. In the end, you could face this to the internet and only allow non signed in users to view and not edit the site. I would either try following this by downloading ubuntu 18.04 for a local VM in free VMplayer, a local Ubuntu on a laptop, or get a cheap 1gb VPS to play on. Because I am going to use Docker you can't really break much on the OS itself. Should work on 20.04, but its still a bit new for now. https://releases.ubuntu.com/18.04.4/ My github for the scripts as I add them. https://github.com/buzzkillb/snakes-on-a-chain The idea is maybe another person will see this and tweak things to be more simple and generic. First update and upgrade everything on the stock ubuntu sudo apt update sudo apt upgrade Next install Docker https://docs.docker.com/engine/install/ubuntu/ The important thing once you are done is to give permission to your new user to use the docker sudo usermod -aG docker your-user I am using user denarius for this sudo usermod -aG docker denarius Close your terminal, open up a new one and check it works. Might even need to restart. We don't want to be running this with sudo everytime. docker run hello-world When it works it will pull the container from dockerhub and show you a cute Hello World message. Lets get Grafana setup, which is just as easy. First we create a data folder to store some local stuff from the container, and also use ID for our current user. mkdir data ID=$(id -u) Run the Docker command docker run -d \ -p 3000:3000 \ --name=grafana \ --user $ID \ --volume "$PWD/data:/var/lib/grafana" \ -e "GF_INSTALL_PLUGINS=grafana-worldmap-panel" \ -e "GF_USERS_VIEWERS_CAN_EDIT=false" \ -e "GF_USERS_EDITORS_CAN_ADMIN=false" \ -e "GF_USERS_ALLOW_SIGN_UP=false" \ -e "GF_USERS_ALLOW_ORG_CREATE=false" \ -e "GF_AUTH_DISABLE_LOGIN_FORM=false" \ -e "GF_AUTH_ANONYMOUS_ENABLED=true" \ -e "GF_AUTH_ANONYMOUS_ORG_ROLE=Viewer" \ -e "GF_ANALYTICS_GOOGLE_ANALYTICS_UA_ID=UA-157676508-1" \ -e "GF_SERVER_DOMAIN=denarius.pro" \ grafana/grafana We will port forward port 3000 from the container to our local machine, which grafana runs on port 3000. Throw in a plugin as an example. Add some variables so a user can't edit our public website, throw in analytics just because, and then give a domain. If you want you can remove all the -e lines. If you start to play around with that you would stop the container, remove the container and rerun whatever full run command you want. docker stop grafana docker rm grafana and then rerun without the -e lines. So running the above line we see Unable to find image 'grafana/grafana:latest' locally latest: Pulling from grafana/grafana cbdbe7a5bc2a: Pull complete ed18d4ca725a: Pull complete 5ac007dea7db: Pull complete 33b8e7fbf663: Pull complete 09cd2fb04616: Pull complete 990c0b335bdb: Pull complete Digest: sha256:4bbfcbf9372e1022bf51b35ec1aaab04bf46e01b76a1d00b424f45b63cf90967 Status: Downloaded newer image for grafana/grafana:latest d593501ecdb6633acc3be6b472fb86eebea10772e58bfaf130f7a05f53de2f94 Lets check its running from the command line. docker ps and we see CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES d593501ecdb6 grafana/grafana "/run.sh" 31 seconds ago Up 30 seconds 0.0.0.0:3000->3000/tcp grafana Its running, now check its working. by opening up a web browser and going to your IP or your local VM. I am using http://127.0.0.1:3000 We want to sign in But whoops we can't create new accounts. Lets do that again docker stop grafana docker rm grafana Now rerun without any -e variables, just so we have entire control. docker run -d \ -p 3000:3000 \ --name=grafana \ --user $ID \ --volume "$PWD/data:/var/lib/grafana" \ grafana/grafana Reload the webpage and type admin and admin and we get prompted for a new password. Make a strong random password here. Firefox gives a random password, use something strong here. Now we see the full panel to start modifying. There is a lot going on, so I would suggest spending some time one day and clicking on every single button you see. And see where it goes. In the meantime lets start getting some stats running so when we modify the panel and dashboard we have some data to look at. Go back to the terminal and run InfluxDB container. docker run -d \ --name="influxdb" \ -p 8086:8086 \ -v /home/denarius/influxdb:/var/lib/influxdb \ influxdb -config /etc/influxdb/influxdb.conf Again we will see influxdb being pulled from dockerhub Unable to find image 'influxdb:latest' locally latest: Pulling from library/influxdb 1c6172af85ee: Pull complete b194b0e3c928: Pull complete 1f5ec00f35d5: Pull complete 256a3fda0bc5: Pull complete 189579438204: Pull complete 855d46376ade: Pull complete 5d599164b1bb: Pull complete 294856b09ff2: Pull complete Digest: sha256:68b3ff6f43ffdb6fe7cf067879e2b28788eff1ebf9b104443c8c2bf3e32c43cf Status: Downloaded newer image for influxdb:latest ecbd84add640c2becc090bf19448f6cc1fddf7bd569bf682bee9e083064f6e85 Check our containers running docker ps and we get CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES ecbd84add640 influxdb "/entrypoint.sh -con…" 26 seconds ago Up 24 seconds 0.0.0.0:8086->8086/tcp influxdb 4b197777eedc grafana/grafana "/run.sh" 4 minutes ago Up 4 minutes 0.0.0.0:3000->3000/tcp grafana Easy now we have our main docker containers running. Lets grab 2 exchange API's and start throwing them in. The scripts I have use python not python 3, so we need to get python if we don't have it already. sudo apt install python Check we have Python 2 python --version We also need a couple other python related things. I am using requests in my scripts, and also we need a connector for python and influxdb. sudo apt install python-pip pip install requests pip install influxdb Now to get some scripts to test with. mkdir python cd python wget https://raw.githubusercontent.com/buzzkillb/snakes-on-a-chain/master/coingecko_southxchange_btc.py wget https://raw.githubusercontent.com/buzzkillb/snakes-on-a-chain/master/coingecko_tradeogre_btc.py The scripts throw SouthXchange and TradeOgre Denarius price in relation to BTC into 2 databases. Lets create those before we run these, as the database doesn't exist yet. Go into our influxdb docker container docker exec -it influxdb /bin/bash run influx in the container to modify the database influx We are in, good job. Lets check what databases are there. show databases This is a good sign, now create the databases for the 2 API calls. create database coingecko_southxchange_btc create database coingecko_trade_btc show databases exit and exit to get out of the container. exit exit Lets start running the scripts in a cronjob every minute to start populating the databases. I use nano, use whatever you like for the editor. crontab -e Insert these 2 lines to run the scripts every minute to pull the data. My username is denarius, you would put your username here for the full path. * * * * * $(which python) /home/denarius/python/coingecko_tradeogre_btc.py >> ~/cron.log 2>&1 * * * * * $(which python) /home/denarius/python/coingecko_southxchange_btc.py >> ~/cron.log 2>&1 When you save and exit the scripts will be running. Check the crontab log cat ~/cron.log I used the wrong database for TradeOgre. Follow the steps above to go back in and create the proper database called coingecko_ogre_btc. Lets drop the wrong one. drop database coingecko_trade_btc And check what we have now. show databases Very easy to modify things. So we have a database being populated while we walk through this. Lets connect the InfluxDB database into Grafana. Go back to your web browser and click the gear -> Data Source Add data source Type in influx, InfluxDB will pop up and click that. Lets go back to the terminal to find our local influxdb docker container ip address to connect to for the connection. docker inspect --format='{{.Name}} {{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -q) I get /influxdb 172.17.0.3 /grafana 172.17.0.2 influxdb will then connect to 172.17.0.3:8086 Now create a SouthXchange Data Source Then click Save & Test and if it worked we get a green Data source is working Click back and lets add TradeOgre Save & Test and lets move onto showing the data. Go to the left side of the screen and click + -> Dashboard Add new panel. First thing I do if I know I am mixing databases together is select Mixed from the dropdown box. For SouthXchange settings. Where distinct is you would click on mean() and then remove, then go to Aggregations and then Distinct. TradeOgre settings. For the first part of the graph panel I give the panel a name and then make the lines and gradient a little prettier. Now we want a side by side graph so BTC is on the left and USD is on the right. Go to Series overriders and type in the regex box and it will give you your ALIAS BY from the left side. Select this one first. Select Y-Axis and then 2. Do this again for TradeOgre USD and will look like this. Our left is BTC price and right is USD, also 8 decimals for for Lefy Y. To find the Unit, click Unit -> Currency and find USD and Bitcoin. Also change labels, and should look like this. I make the table so I can see more stats fast, and also force decimals to 8 places. Click refresh button to update the chart and then change colors to something different. I like blue and purple, then click Save. Give this a name, sometimes it doesn't stick, but lets try. Now we want to change refresh of the chart and also click star to make this a dashboard we can set for home. Its now starred and 1m refresh since the cronjob is set to run every 60 seconds. If we click on the top left grafana button we still get the stock dashboard. Lets change that. Gear -> Preferences I use these settings and then click save. Clicking the top left Grafana logo we now get our new chart as our homepage. Now lets stop and remove grafana and rerun with our variables. For the test I am going to remove the domain and analytics. docker stop grafana docker rm grafana docker command with those couple of -e lines removed for the final test. docker run -d \ -p 3000:3000 \ --name=grafana \ --user $ID \ --volume "$PWD/data:/var/lib/grafana" \ -e "GF_INSTALL_PLUGINS=grafana-worldmap-panel" \ -e "GF_USERS_VIEWERS_CAN_EDIT=false" \ -e "GF_USERS_EDITORS_CAN_ADMIN=false" \ -e "GF_USERS_ALLOW_SIGN_UP=false" \ -e "GF_USERS_ALLOW_ORG_CREATE=false" \ -e "GF_AUTH_DISABLE_LOGIN_FORM=false" \ -e "GF_AUTH_ANONYMOUS_ENABLED=true" \ -e "GF_AUTH_ANONYMOUS_ORG_ROLE=Viewer" \ grafana/grafana Go back to your web browser, refresh and sign out. It kicks us back to the login screen. Retype the local IP of 127.0.0.1:3000 and now we can view our new dashboard. Make edits to sizing and stuff by signing back in and editting however you want. I left this line in the commands so I can easily edit dashboards and then stop rm and change this to true on the docker container restart, like this. -e "GF_AUTH_DISABLE_LOGIN_FORM=true" \ Once you get it going probably install fail2ban and ufw. And deny everything but whatever ports you end up needing to run this as a public site. Also maybe remove root password login and only use ssh keys. Then run behind cloudflare if that's your thing. Next will be a guide on how to include the daemon and some other stats.
  3. I think this is an easier way to setup an electrumx server. It's not that bad once you go through the steps. Trying to be thorough. Install docker My github for this. https://github.com/buzzkillb/docker-electrumx We will end up running denariusd in a container and electrumx in a container. First create a folder on your server or vps to store the denarius blockchain. This can be anywhere, but lets make this easy. cd ~ mkdir .denarius cd .denarius nano denarius.conf Sample denarius.conf, pay attention as we will need the rpcuser and rpcpassword. rpcuser=denariusrpc rpcpassword=MAKEUPSOMEPASSWORD maxconnections=125 rpcport=32369 port=33369 daemon=0 listen=1 server=1 discover=1 txindex=1 bind=127.0.0.1:33369 We either sync from block 0 or use chaindata. You decide. Now we can run the denariusd docker container. docker run \ --net=host \ --name=denariusd \ -t -d \ -p 33369:33369 \ -p 32369:32369 \ -v ~/.denarius:/data \ -P buzzkillb/denariusd:latest To check the sync docker logs denariusd -f ctrl+c to exit out of that whenever Now to run electrumx server (wait to be fully sync'd). docker run \ --name=electrumx \ --net=host \ --ulimit nofile=5120:5120 \ -t -d \ -v ~/electrumx:/data \ -e DAEMON_URL=http://denariusrpc:[email protected]:32369 \ -e COIN=Denarius \ -e DB_ENGINE=rocksdb \ -p 50001:50001 \ -p 50002:50002 \ buzzkillb/docker-electrumx:latest To watch these logs. docker logs electrumx -f Once running check it can be found. openssl s_client -connect electrumx1.denarius.pro:50002 Working on an easy way to do the compaction. If you stop the container and then run docker run \ --name=electrumx-compact \ --net=host \ --ulimit nofile=5120:5120 \ -t -d \ -v ~/electrumx:/data \ -e DAEMON_URL=http://denariusrpc:[email protected]:32369 \ -e COIN=Denarius \ -e DB_ENGINE=rocksdb \ -p 50001:50001 \ -p 50002:50002 \ buzzkillb/docker-electrumx:dcompact This will compact the database using Denarius environment variables. With both containers electrumx and electrumx-compact both up, we can now add a cronjob to stop server, start compact, and restart server. crontab -e Run daily, this is overkill. Best to run every 14 days or less. 0 0 * * * docker stop electrumx >/dev/null 2>&1 1 0 * * * docker start electrumx-compact >/dev/null 2>&1 6 0 * * * docker start electrumx >/dev/null 2>&1
  4. So I made this https://github.com/buzzkillb/denariusQTdocker with a command line script of this #!/bin/bash XSOCK=/tmp/.X11-unix XAUTH=/tmp/.docker-xauth mkdir -p ${HOME}/.denarius xauth nlist ${DISPLAY} | sed -e 's/^..../ffff/' | xauth -f ${XAUTH} nmerge - docker run -ti --rm -e "XAUTHORITY=${XAUTH}" -e "DISPLAY=${DISPLAY}" -v ${HOME}/.denarius:/denarius -v ${XAUTH}:${XAUTH} -v ${XSOCK}:${XSOCK} --name="denarius-qt-d" --user="${UID}:${GID}" buzzkillb/denariusqt:latest Which the QT works on Ubuntu 19.04 Going to throw a bunch of random ideas on how to run this on other os's in here.
  5. Playing with using denariusd and tor in their own docker network. I am bypassing denariusd nativetor for some other reasons right now. denariusd:alpha is the test branch I am creating on docker hub using the latest denariusd wallet daemon. ~/.denarius/denarius.conf should be populated along with /etc/tor/torrc docker-compose.yml version: '3.2' services: tor: image: buzzkillb/tor:alpine container_name: tor networks: - tor_network volumes: - /etc/tor/torrc:/etc/tor/torrc restart: always denariusd: image: buzzkillb/denariusd:alpha container_name: denariusd volumes: - ~/.denarius:/data command: -debug=0 network_mode: service:tor depends_on: - tor restart: always networks: tor_network: external: true docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 48e24fa60efd buzzkillb/denariusd:alpha "denariusd --datadir…" 8 seconds ago Up 7 seconds denariusd 81119081a083 buzzkillb/tor:alpine "/bin/sh -c '/usr/bi…" 19 seconds ago Up 17 seconds 53/udp, 9050/tcp tor Connecting into the TOR nodes I have setup all over the place, something like this should appear in the denariusd logs. docker logs denariusd -f SetBestChain: new best=8499db50db63985aa0ad height=2235381 trust=14348364472433105438 blocktrust=1048577 date=08/03/19 15:48:36 SOCKS5 connected hrzdbqp4vjbohsvg.onion send version message: version 33500, blocks=2235381, us=tyfj5y64rlocawsb.onion:33369, them=hrzdbqp4vjbohsvg.onion:33369, peer=hrzdbqp4vjbohsvg.onion:33369 SetBestChain: new best=000000000019e5f675cb height=2235382 trust=14348373734367204915 blocktrust=9261934099477 date=08/03/19 15:48:44 SOCKS5 connecting 6nw6dekrzc2s5i2w.onion Once I get this working like I want, I will throw in a VPN connection.
  6. This may or may not be an easier way to control your fortunastake servers. Its for sure an easy way to run more than 1 on same PC as long as that PC / raspberry pi / tablet?? / whatever can run Docker. Can also run nativetor in each container, which is an interesting way to run onion FS's. If you do this guide once, you will see why I went through so much trouble to write this out. Github is located here with the dockerfiles https://github.com/buzzkillb/denariusDocker How to install docker on ubuntu 16.04. Might be different on newer releases, disco dingo has a snap package, just putting basic install here to show what the commands are. https://docs.docker.com/install/linux/docker-ce/ubuntu/ sudo apt-get update sudo apt-get install \ apt-transport-https \ ca-certificates \ curl \ gnupg-agent \ software-properties-common curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - sudo add-apt-repository \ "deb [arch=amd64] https://download.docker.com/linux/ubuntu \ $(lsb_release -cs) \ stable" sudo apt-get update sudo apt-get install docker-ce docker-ce-cli containerd.io To test it installed correctly. sudo docker run hello-world modify your user account so you dont need to run sudo on the docker commands. sudo usermod -aG docker your-user Now to the good stuff. as of v3.3.9.1 denariusd creates a denarius.conf in the datadir, so we can handle this 2 ways. Either run the docker daemon and let it autocreate denarius.conf and then edit that, or just create denarius.conf before running the docker daemon. The main thing to know is that the docker daemon requires daemon=0. Setup typical denarius.conf to enable fortunastake server. typical chaindata directory is ~/.denarius but this can go anywhere. like ~/D/FS01 example denarius.conf rpcuser=USEARANDOMNAME rpcpassword=USEARANDOMPASSWORD daemon=0 port=9999 fortunastake=1 fortunastakeprivkey=6J8tAUsVchangethisofcoursehXBgfdeewqsdghySWEQEeb4XGSC251sM7bYQgEXh7 Lets run from ~/.denarius to get started. This will run the docker container of latest wallet daemon compiled from source using ubuntu 18.04 as the OS. I also created one that uses ubuntu 16.04, and one that works on armv7 devices like a raspberry pi3. For now lets use the first one I made. docker run --name=denariusd --rm -t -d -v ~/.denarius:/data -P buzzkillb/denariusd What this does is pulls and runs the docker daemon container and uses your ~/.denarius folder as the data storage. So if you shutdown the container your data isnt inside of that container and gets lost on any shutdowns. A hint: this folder is where your denarius.conf is located. change ~/.denarius to ~/D/FS01 and now you can make many if you want. Just stick a denarius.conf in FS01, FS02, FS03, etc. Some basic commands to use this. docker exec denariusd denariusd -datadir=/data getinfo docker exec denariusd denariusd -datadir=/data getbalance docker exec denariusd denariusd -datadir=/data fortunastake status To read the logs, (this is like tail -f debug.log) docker logs denariusd -f Now lets say you ran many of these containers for many fortunastakes. You would run it like this. docker run --name=FS01 --rm -t -d -v ~/D/FS01:/data -P buzzkillb/denariusd Even easier, install docker-compose https://docs.docker.com/compose/install/ and then create a directory to store a docker compose file in, like cd ~ mkdir bigd cd bigd nano docker-compose.yml Stick this in the yml file. FS01: image: buzzkillb/denariusd:latest volumes: - ~/D/FS01:/data FS02: image: buzzkillb/denariusd:latest volumes: - ~/D/FS02:/data FS03: image: buzzkillb/denariusd:latest volumes: - ~/D/FS03:/data then in that folder docker-compose up -d This will start 3 fortunastakes on the same PC. Just need about 700mb of ram per FS. I have some more examples of commands on the github link, but this should get someone started on making this a bit easier. I will build the latest daemon on these, so if you want to autoupdate whenever these happen, try out watchtower. https://github.com/containrrr/watchtower docker run -d \ --name watchtower \ -v /var/run/docker.sock:/var/run/docker.sock \ containrrr/watchtower This will stop the container, pull the latest, and restart from same command used to start. I am also using dozzle to watch the logs from a web browser. https://github.com/amir20/dozzle docker run --name dozzle -d --volume=/var/run/docker.sock:/var/run/docker.sock -p 8888:8080 amir20/dozzle:latest
  7. Docker can be used to run a denariusd wallet daemon. It can also run multple FortunaStakes very easily. No need to mess with compiling or downloading binaries. My github has some basics for the docker image I created. https://github.com/buzzkillb/denariusDocker First install docker on ubuntu. Don't forget to usermod your user account to run docker commands without using sudo. https://docs.docker.com/install/linux/docker-ce/ubuntu/ Once docker-ce is running lets grab my docker image. docker run --name=denariusd --rm -t -v ~/.denarius:/data -P buzzkillb/denariusd First thing we notice is that we need a denarius.conf in the ~/.denarius folder. Lets make one with what we need. nano ~/.denarius/denarius.conf rpcuser=usernamechangeme rpcpassword=passwordchangeme Save and now run the above command again. docker run --name=denariusd --rm -t -v ~/.denarius:/data -P buzzkillb/denariusd Was that easy or what? Now to run this in the background add -d flag. docker run --name=denariusd --rm -t -d -v ~/.denarius:/data -P buzzkillb/denariusd With the output not being shown. Lets watch the printtoconsole lines in the docker container. docker logs denariusd -f To list all your containers. docker ps To stop your container. docker stop denariusd You can run more than 1 container of denariusd, example below docker run --name=FS01 --rm -t -d -v ~/FS01:/data -P buzzkillb/denariusd Have fun!
  8. How to setup a compiled from source Denarius daemon docker container in Ubuntu 16.04. I setup an Ubuntu 16.04 VM using Virtual Box to start this out. Work in progress as there are a few steps and links I need to add over time. Install Docker on your host machine. https://docs.docker.com/install/linux/docker-ce/ubuntu/ create a folder to work in mkdir denarius-ubuntu First we setup the update and install dependencies files. nano Dockerfile.dev FROM ubuntu:16.04 RUN apt-get update -y && \ apt-get dist-upgrade -y && \ apt-get install -y git \ unzip \ build-essential \ libssl-dev \ libdb++-dev \ libboost-all-dev \ libqrencode-dev \ libminiupnpc-dev \ libgmp-dev \ libevent-dev \ autogen \ automake \ libtool Then we build this docker build -f Dockerfile.dev -t ubuntu-dev . Next we setup getting the source code. nano Dockerfile.build FROM ubuntu-dev RUN git clone https://github.com/carsenk/denarius Then we build this docker build -f Dockerfile.build -t denarius-ubuntu-build . Setup the compile nano Dockerfile.compile FROM denarius-ubuntu-build RUN (cd denarius && \ git checkout master && \ git pull && \ cd src && \ make -f makefile.unix ) Then we build this docker build -f Dockerfile.compile -t denarius-ubuntu-compile . Setup the move binary nano Dockerfile.install #Dockerfile.install FROM denarius-ubuntu-compile COPY --from=denarius-ubuntu-compile /denarius/src/denariusd /usr/local/bin Then we build this docker build -f Dockerfile.install -t denarius-ubuntu-bin . Setup a denarius.conf. nano denarius.conf rpcuser=RandomUserNameSy5pess55rGu9EsGF0+ZXc/RZlON41+x rpcpassword=RandomPasswordREy9PYjgNdmFdDgWmpXnsotQ42cURu4cO22xknJEXsItXkydbSa0kxcxbvt2hE+g nativetor=1 server=1 listen=1 daemon=1 Setup to move the denarius.conf and expose ports. nano Dockerfile.run #Dockerfile.run FROM denarius-ubuntu-bin # # Copy the denarius.conf file from # the build context into the container # COPY denarius.conf /root/.denarius/denarius.conf # # Expose ports for the RPC interface # EXPOSE 33369 9999 Then we build this. docker build -f Dockerfile.run -t denarius-ubuntu-run . Now we have a bunch of images, which we can see by using the command docker images. I liked the idea of running the container and linking to a directory on the host machine itself. Sample directory being ~/blockchain on the host. docker run --rm -it -d -v ~/blockchain:/root/.denarius -P denarius-ubuntu-run bash Finally if you want to remove some of the bloat and push to your own docker hub create a Dockerfile. nano Dockerfile FROM denarius-ubuntu-bin as build RUN echo "In build stage" FROM ubuntu:16.04 COPY --from=build /usr/local/bin/denariusd /usr/local/bin #Get packages and Dependencies RUN apt-get update -y && \ apt-get dist-upgrade -y && \ apt-get install -y git \ unzip \ build-essential \ libssl-dev \ libdb++-dev \ libboost-all-dev \ libqrencode-dev \ libminiupnpc-dev \ libgmp-dev \ libevent-dev \ autogen \ automake \ libtool #Pull from Source #RUN git clone https://github.com/carsenk/denarius #Compile from Source #RUN (cd denarius && \ #git checkout master && \ #git pull && \ #cd src && \ #make -f makefile.unix ) # # Copy the denarius.conf file from # the build context into the container # COPY denarius.conf /root/.denarius/denarius.conf # # Expose ports for the RPC interface # EXPOSE 33369 9999 # # Start the bitcoin server # #ENTRYPOINT ["/usr/local/bin/denariusd"] Build and commit this. A good step by step on how to push your new docker image to docker hub. https://ropenscilabs.github.io/r-docker-tutorial/04-Dockerhub.html
  9. Location of script. https://github.com/buzzkillb/denariuscoin-Dockerfiles Run this on a VPS bash -c "$(wget -O - https://raw.githubusercontent.com/buzzkillb/denariuscoin-Dockerfiles/master/createswap.sh)" && bash -c "$(wget -O - https://raw.githubusercontent.com/buzzkillb/denariuscoin-Dockerfiles/master/install.sh)" After it finishes installing. Then go to https://YOURSERVERIP After inputting the key, you are done with the VPS portion. at the command prompt type To List docker ps To enter the container. docker exec -it denariuscoinmasternode bash Sample commands /root/.denarius/denariusd getinfo /root/.denarius/denariusd masternode status
×
×
  • Create New...