forked from masternodes/vps
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2e5ee9a
commit 5ec7d35
Showing
54 changed files
with
1,177 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
.DS_Store* | ||
code/* | ||
.DS_Store* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,21 +36,21 @@ vps:~ su - pivxd | |
``` | ||
|
||
# Todo | ||
<<<<<<< HEAD | ||
* rewrite for config templates and provide my Dockerfile & Vagrantfile | ||
======= | ||
>>>>>>> 71c62b0bdc2ba8772d19c73a3941e06f6f087c7f | ||
* document the vultr signup and setup procedure | ||
* provide a delete / uninstall flag | ||
* create a logfile | ||
* instert coin images into readme | ||
* insert vultr signup reflink | ||
* make scripts idempotent | ||
* write test cases | ||
* implement a binary option (?) | ||
* outsource common variables in commin source file | ||
* check if masternode user already exists before creation | ||
* add all flags everywhere ./configure --disable-dependency-tracking --enable-tests=no --without-gui --without-miniupnpc --with-incompatible-bdb CFLAGS="-march=native" LIBS="-lcurl -lssl -lcrypto -lz" | ||
|
||
# Errors | ||
* currently not fully idempotent (cfengine?) | ||
* currently not fully idempotent | ||
* check if relevant interface already exists (sed) before writing to interfaces file | ||
|
||
|
||
|
@@ -59,13 +59,8 @@ Ping me at [email protected] for questions and send some crypto my way if | |
**Have fun, this is crypto after all!** | ||
``` | ||
BTC 1PboFDkBsW2i968UnehWwcSrM9Djq5LcLB | ||
<<<<<<< HEAD | ||
PIVX DQS4rk57bteJ42FSNSPpwqHUoNhx4ywfQc | ||
======= | ||
DNET DBGBYLz484dWBb5wtk5gFVdJ8rGFfcob7R | ||
SYNX SSKYwMhQQt9DcWozt7zA1tR3DmRuw1gT6b | ||
DASH Xt1W8cVPxnx9xVmfe1yYM9e5DKumPQHaV5 | ||
MUE 7KV3NUX4g7rgEDHVfBttRWcxk3hrqGR4pH | ||
MOJO MTfuWof2NMDPh57U18yniVzpaS2cq4nFFt | ||
>>>>>>> 71c62b0bdc2ba8772d19c73a3941e06f6f087c7f | ||
``` | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# -*- mode: ruby -*- | ||
# vi: set ft=ruby : | ||
Vagrant.configure("2") do |config| | ||
|
||
# The vbguest plugin automatically installs the proper guest utils | ||
# vagrant plugin install vagrant-vbguest | ||
# https://github.com/dotless-de/vagrant-vbguest | ||
if Vagrant.has_plugin?("vbguest") | ||
config.vbguest.auto_update = true | ||
config.vbguest.iso_path = "http://download.virtualbox.org/virtualbox/%{version}/VBoxGuestAdditions_%{version}.iso" | ||
end | ||
|
||
# caching to speed-up box provisioning | ||
# vagrant plugin install vagrant-cachier | ||
# https://github.com/fgrehm/vagrant-cachier | ||
if Vagrant.has_plugin?("vagrant-cachier") | ||
# Configure cached packages to be shared between instances of the same base box. | ||
# More info on http://fgrehm.viewdocs.io/vagrant-cachier/usage | ||
config.cache.scope = :box | ||
end | ||
|
||
# provisioning stuff here | ||
config.vm.box = "ubuntu/xenial64" | ||
config.vm.define "testbox" do |node| | ||
node.vm.hostname = "testbox" | ||
node.vm.provider "virtualbox" do |vb| | ||
vb.gui = false | ||
vb.memory = "3096" | ||
end | ||
node.vm.network "private_network", ip: "10.10.20.10" | ||
node.vm.synced_folder '.', '/vagrant' | ||
node.ssh.forward_agent = true | ||
node.ssh.insert_key = true | ||
# Remove all stdin is not a tty errors | ||
node.vm.provision "fix-no-tty", type: "shell" do |s| | ||
s.privileged = false | ||
s.inline = "sudo sed -i '/tty/!s/mesg n/tty -s \\&\\& mesg n/' /root/.profile" | ||
end | ||
node.vm.provision :shell, :privileged => true, :path => "setup.sh" | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
rpcuser=XXXXXXXXXXXXX | ||
rpcpassword=XXXXXXXXXXXXXXXXXXXXXXXXXXXX | ||
rpcallowip=127.0.0.1 | ||
#---- | ||
listen=1 | ||
server=1 | ||
daemon=1 | ||
maxconnections=50 | ||
#-------------------- | ||
masternode=1 | ||
masternodeprivkey=XXXXXXXXXXXXXXXXXXXXXXX | ||
externalip=XXX.XXX.XXX.XXX |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
rpcuser=monetaryunitrpc | ||
rpcpassword=HnPdbu2piYSEpcYZnw3eLZqkExAyoA6XAS6V3bPKefkB | ||
rpcallowip=127.0.0.1 | ||
#---- | ||
listen=1 | ||
server=1 | ||
daemon=1 | ||
maxconnections=50 | ||
#-------------------- | ||
masternode=1 |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
./autogen.sh | ||
./configure --disable-dependency-tracking --enable-tests=no --without-gui --without-miniupnpc --with-incompatible-bdb CFLAGS="-march=native" LIBS="-lcurl -lssl -lcrypto -lz" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#!/bin/bash | ||
cd src | ||
make -f makefile.unix USE_UPNP=- | ||
#strip mojocoind | ||
cp mojocoind ${MNODE_DAEMON} | ||
#strip sibcoind | ||
cp sibcoind ${MNODE_DAEMON} | ||
cd .. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
CODENAME=sib | ||
SETUP_MNODES_COUNT=${SETUP_MNODES_COUNT:-1} | ||
MNODE_DAEMON=${MNODE_DAEMON:-/usr/local/bin/sibcoind} | ||
GIT_PROJECT=sib | ||
NETWORK_BASE_TAG="2004" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
./autogen.sh | ||
./configure --disable-dependency-tracking --enable-tests=no --without-gui --without-miniupnpc --with-incompatible-bdb CFLAGS="-march=native" LIBS="-lcurl -lssl -lcrypto -lz" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
# | ||
# Dockerfile for a ARC masternode | ||
# usage: docker run marsmensch/masternode-arc:latest | ||
# | ||
# how to work with the container | ||
# | ||
# 1) build the container (checkout desired git revision first) | ||
# docker build -t "marsmensch/masternode-arc:latest" -f docker/Dockerfile_BSD . | ||
# | ||
# 2) start the container | ||
# docker run -p ${NODE_PORT}:${NODE_PORT} -v $(PWD)/config/arc/arcticcoind.conf:/opt/data "marsmensch/masternode-arc:latest" | ||
# | ||
# 3) start the container interactively | ||
# docker run --interactive --tty --entrypoint=/bin/bash "marsmensch/masternode-arc:latest" | ||
# | ||
# 4) standard help | ||
# docker run -v $(PWD)/config/arc:/opt/data "marsmensch/masternode-arc:latest" | ||
|
||
FROM ubuntu:xenial | ||
MAINTAINER Florian Maier <[email protected]> | ||
|
||
#ARG USER_ID | ||
#ARG GROUP_ID | ||
|
||
# SET BUILD VARS TO RUNTIME VARS | ||
#ARG var | ||
#ENV var=${var} | ||
|
||
ENV HOME /bitcoin | ||
|
||
# add user with specified (or default) user/group ids | ||
#ENV USER_ID ${USER_ID:-1000} | ||
#ENV GROUP_ID ${GROUP_ID:-1000} | ||
|
||
ENV CONTAINER_USER masternode | ||
ENV PROJECT arcticcoin | ||
ENV GIT_URL git://github.com/ArcticCore/arcticcoin.git | ||
ENV SVC_VERSION tags/v0.12.1.2 | ||
ENV HOME_DIR /usr/local/bin | ||
ENV NODE_PORT 7209 | ||
ENV REFRESHED_AT 2017-07-27 | ||
|
||
# add unprivileged user | ||
RUN adduser --shell /bin/bash --disabled-password \ | ||
--disabled-login --gecos '' ${CONTAINER_USER} | ||
|
||
# install system packages and compile | ||
RUN apt-get update \ | ||
&& apt-get -y upgrade \ | ||
&& apt-get -y install --no-install-recommends build-essential libtool autotools-dev \ | ||
libcurl4-openssl-dev libboost-all-dev libssl-dev libdb++-dev make autoconf automake \ | ||
libtool git apt-utils libprotobuf-dev pkg-config libboost-filesystem-dev libboost-chrono-dev \ | ||
libevent-dev libboost-program-options-dev libgmp-dev libboost-test-dev libboost-thread-dev \ | ||
&& mkdir -p /opt/code/ && cd /opt/code/ && git clone ${GIT_URL} ${PROJECT} \ | ||
&& cd /opt/code/${PROJECT} && git checkout ${SVC_VERSION} \ | ||
&& ./autogen.sh && ./configure --enable-tests=no --with-incompatible-bdb \ | ||
--enable-glibc-back-compat --with-gui=no \ | ||
CFLAGS="-march=native" LIBS="-lcurl -lssl -lcrypto -lz" \ | ||
&& make && make install \ | ||
# remove unneeded stuff | ||
&& apt-get -y remove build-essential \ | ||
libboost-all-dev libboost-atomic-dev libboost-atomic1.58-dev \ | ||
libboost-chrono-dev libboost-chrono1.58-dev \ | ||
libboost-context-dev libboost-context1.58-dev \ | ||
libboost-coroutine-dev libboost-coroutine1.58-dev \ | ||
libboost-date-time-dev libboost-date-time1.58-dev \ | ||
libboost-dev libboost-exception-dev libboost-exception1.58-dev \ | ||
libboost-filesystem-dev libboost-filesystem1.58-dev \ | ||
libboost-graph-dev libboost-graph-parallel-dev \ | ||
libboost-graph-parallel1.58-dev libboost-graph1.58-dev \ | ||
libboost-iostreams-dev libboost-iostreams1.58-dev libboost-locale-dev \ | ||
libboost-locale1.58-dev libboost-log-dev \ | ||
libboost-log1.58-dev libboost-log1.58.0 libboost-math-dev \ | ||
libboost-math1.58-dev libboost-math1.58.0 libboost-mpi-dev \ | ||
libboost-mpi-python-dev libboost-mpi-python1.58-dev \ | ||
libboost-mpi1.58-dev libboost-program-options-dev \ | ||
libboost-program-options1.58-dev libboost-python-dev \ | ||
libboost-python1.58-dev libboost-random-dev libboost-random1.58-dev \ | ||
libboost-regex-dev libboost-regex1.58-dev libboost-serialization-dev \ | ||
libboost-serialization1.58-dev libboost-signals-dev libboost-signals1.58-dev \ | ||
libboost-system-dev libboost-system1.58-dev libboost-test-dev libboost-test1.58-dev \ | ||
libboost-thread-dev libboost-thread1.58-dev libboost-timer-dev libboost-timer1.58-dev \ | ||
libboost-tools-dev libboost-wave-dev libboost-wave1.58-dev libboost1.58-dev \ | ||
libboost1.58-tools-dev libc6-dev libdb5.3++-dev libdb5.3-dev libevent-dev \ | ||
libexpat1-dev libgmp-dev libibverbs-dev libicu-dev libltdl-dev libnuma-dev \ | ||
libopenmpi-dev libprotobuf-dev libpython-dev libpython2.7-dev libssl-dev \ | ||
mpi-default-dev python-dev python2.7-dev zlib1g-dev \ | ||
&& apt -y autoremove \ | ||
&& rm -rf /opt/code \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# EXPOSE the masternode port | ||
EXPOSE ${NODE_PORT} | ||
|
||
RUN chown -R ${CONTAINER_USER} ${HOME_DIR} | ||
USER ${CONTAINER_USER} | ||
WORKDIR ${HOME_DIR} | ||
|
||
# start command | ||
ENTRYPOINT ["/usr/local/bin/arcticcoind", "screen", "-A", "-m", "-d", "-S", "daemon"] | ||
CMD ["--help"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# | ||
# Dockerfile for a BLOCK servicenode | ||
# usage: docker run marsmensch/servicenode-block:latest | ||
# | ||
# how to work with the container | ||
# | ||
# 1) build the container (checkout desired git revision first) | ||
# docker build -t "marsmensch/servicenode-block:latest" -f docker/Dockerfile_BLOCK . | ||
# | ||
# 2) start the container | ||
# docker run -p ${NODE_PORT}:${NODE_PORT} -v $(PWD)/config/block/blockd.conf:/opt/data "marsmensch/servicenode-block:latest" | ||
# | ||
# 3) start the container interactively | ||
# docker run --interactive --tty --entrypoint=/bin/bash "marsmensch/servicenode-block:latest" | ||
# | ||
# 4) standard help | ||
# docker run -v $(PWD)/config/block:/opt/data "marsmensch/servicenode-block:latest" | ||
|
||
FROM ubuntu:xenial | ||
MAINTAINER Florian Maier <[email protected]> | ||
|
||
ENV CONTAINER_USER servicenode | ||
ENV PROJECT blocknet | ||
ENV GIT_URL git://github.com/atcsecure/blocknet.git | ||
ENV SECP_URL git://github.com/bitcoin-core/secp256k1.git | ||
ENV SVC_VERSION xbridge-new-2 | ||
ENV HOME_DIR /usr/local/bin | ||
ENV NODE_PORT 31337 | ||
ENV REFRESHED_AT 2017-07-28 | ||
|
||
# add unprivileged user | ||
RUN adduser --shell /bin/bash --disabled-password \ | ||
--disabled-login --gecos '' ${CONTAINER_USER} | ||
|
||
# install system packages and compile | ||
RUN apt-get update \ | ||
&& apt-get -y upgrade \ | ||
&& apt-get -y install --no-install-recommends build-essential libtool autotools-dev \ | ||
libcurl4-openssl-dev libboost-all-dev libssl-dev libdb++-dev make autoconf automake \ | ||
libtool git apt-utils libprotobuf-dev pkg-config libboost-filesystem-dev libboost-chrono-dev \ | ||
libevent-dev libboost-program-options-dev libgmp-dev libboost-test-dev libboost-thread-dev \ | ||
&& mkdir -p /opt/code/ && cd /opt/code/ \ | ||
&& git clone ${SECP_URL} && cd secp256k1 && ./autogen.sh \ | ||
&& ./configure --enable-module-recovery && make && make install \ | ||
&& cd /opt/code/ && git clone ${GIT_URL} ${PROJECT} \ | ||
&& cd /opt/code/${PROJECT} && git checkout ${SVC_VERSION} \ | ||
&& cd src && make -f makefile.unix USE_UPNP= \ | ||
&& cp blocknetd /usr/local/bin/blocknetd && ldconfig \ | ||
&& apt -y autoremove \ | ||
&& rm -rf /opt/code \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# EXPOSE the masternode port | ||
EXPOSE ${NODE_PORT} | ||
|
||
#RUN chown -R ${CONTAINER_USER} ${HOME_DIR} | ||
#USER ${CONTAINER_USER} | ||
#WORKDIR ${HOME_DIR} | ||
|
||
# start command | ||
CMD ["/usr/local/bin/blocknetd", "--help"] |
Oops, something went wrong.