This software allows you to easily open a Dagger (XDAG) pool with a nice, comfortable UI available to your users.
- detailed pool and network statistics, including graphs (hashrate, active miners, difficulty, found blocks, ...)
- address balance checker tool
- detailed payouts (exportable) for any pool miner
- list of found blocks by the pool
- detailed guides on how to set-up miners
- rich administration interface allowing to customise many aspects of the website and view admin-related information
- independent of 3rd party services (all data is exported / queried on local pool software)
- secure, with clean code and expandability in mind
- optional registration allows users to manage their miners in one place
- hashrate history for registered miners
- miner offline / miner back online e-mail alerts for registered users
- administrator e-mail alerts: zero pool hashrate, abnormal pool daemon state and reference miner offline
- ability to e-mail active or all pool registered users with important message
- pool status and diagnostic information exports on URLs
/status/human-readable(text file) - updated every minute
- ability to approximate earnings based on hashrate
- mobile friendly design tweaks
- translations and languages support, support for a simple CMS (setup pages, other pool documents and similar)
- code refactoring, use repository and presenters for models, other improvements
- add the ability to customise website design a bit, for example by allowing to upload a
favicon.ico, or change bulma theme as a whole
In order to run the pool you should be fluent in Unix / Linux administration and have basic understanding of computer programming.
- pool version at least 0.2.1
- nginx, php7+, mariadb or mysql, nodejs 8.x
How the pool website works
The pool website periodically fetches required data from the pool daemon-side script. These scripts are in a separate repository. This data is stored locally and then processed.
Processed results are most often stored in a database. The pool re-reads imported data files whenever necessary.
This means the pool website is totally independent of the pool itself. Should the pool daemon-side become unavailable, the pool website would just endlessly display the latest obtained information from the pool daemon.
This giude expects that the pool software with required scripts (openxdagpool-scripts) is up and running, either on website server or on a different server. This installation guide gives an overview on how to get the pool website up and running. It can't go in-depth on every step, however all important details are provided.
Perform the following steps in order to get the website up and running:
- set your system timezone to
dpkg-reconfigure tzdataand choose
- install all PHP7.0 requirements, for Ubuntu 16.04, use
apt-get install php7.0-bcmath php7.0-cli php7.0-common php7.0-fpm php7.0-json php7.0-mbstring php7.0-mcrypt php7.0-mysql php7.0-opcache php7.0-readline php7.0-sqlite3 php7.0-xml php7.0-zip autoconf libtool nasm supervisor. Next configure
php.inito your preference. Set
memory_limitto at least
- install mysql 5.7 or mariadb. Create new database, for example
CREATE DATABASE openxdagpool CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;run as mysql's
rootuser. Grant all privileges to a new user:
GRANT ALL ON openxdagpool.* TO openxdagpool@'%' IDENTIFIED BY 'PWD!!!!';. Choose your own password!
- install nginx and set up a PHP FPM pool running as user of your choice.
- configure nginx to properly execute this website
- install composer and nodejs 8.x
- clone this project into
/var/www/openxdagpool. Proceed as
www-dataor other user that the PHP FPM pool runs as
cp .env.example .env
.envand set up correct values, read the comments for help. Mail settings are required for e-mail alerts to work properly. Make sure to set
falsefor production usage.
php artisan key:generate
php artisan migrate
npm installand then
npm run production
php artisan data:liveand
php artisan data:fast, make sure these commands completed successfully. Then run
php artisan pool:cron.
- install a letsencrypt certificate or other https certificate (optional)
- visit the web site, and register. First registered user is an administrator.
- visit the administration interface to set up your pool settings.
- payouts exports of large datasets require the mysql files privilege. Edit
/etc/mysql/mysql.conf.d/mysqld.cnfand in the
secure-file-priv=/var/www/openxdagpool/public/payouts/. Then execute
GRANT FILE ON *.* TO openxdagpool@'%';as mysql's
rootuser. Restart the mysql daemon using
service mysql restartas
chmod 777 /var/www/openxdagpool/public/payouts/as
- as the PHP FPM pool user, execute
crontab -eand enter one cron line:
* * * * * php /var/www/openxdagpool/artisan schedule:run >> /dev/null 2>&1
- execute as
root, replacing the
userwith the same user the PHP FPM pool runs as:
cat << 'EOD' > /etc/supervisor/conf.d/laravel-worker.conf [program:laravel-worker] process_name=%(program_name)s_%(process_num)02d command=php /var/www/openxdagpool/artisan queue:work --sleep=3 --tries=3 autostart=true autorestart=true user=!!!! REPLACE with the same user as the PHP FPM pool runs as !!!! numprocs=1 redirect_stderr=true stdout_logfile=/var/www/openxdagpool/storage/logs/worker.log EOD
- execute as
supervisorctl start laravel-worker:*
Done! Enjoy your new OpenXDAGPool instance! ;-)
Whenever you update the code using
git pull, observe changed files. If
.env.example changed, observe the changes and modify your
.env file appropriately.
If any file in the
database/migrations folder changed, you need to run
php artisan migrate. When any file under
resources/assets changed, you need to
npm run production. After every
git pull, run
php artisan cache:clear and
supervisorctl restart laravel-worker:* as
If you change your
.env file even without updating the application, don't forget to run
php artisan cache:clear and
supervisorctl restart laravel-worker:*
root for the changes to take place in your queue as well.