Merge branch 'next' of github.com:TheSerapher/php-mpos into next

This commit is contained in:
Sebastian Grewe 2013-11-01 08:30:07 +01:00
commit bd0398d927
8 changed files with 60 additions and 31 deletions

View File

@ -50,8 +50,6 @@ Requirements
This setup has been tested on Ubuntu 12.04, Ubuntu 13.04 and CentOS. This setup has been tested on Ubuntu 12.04, Ubuntu 13.04 and CentOS.
It should also work on any related distribution (RHEL, Debian). It should also work on any related distribution (RHEL, Debian).
For support on how to get `litecoind` or `pushpoold` to work, please ask
in the appropriate forums.
Be aware that `MPOS` is **only** for pooled mining. Solo Mining is not Be aware that `MPOS` is **only** for pooled mining. Solo Mining is not
supported. They will never match an upstream share, solo miners do not create supported. They will never match an upstream share, solo miners do not create
@ -77,16 +75,16 @@ The following feature have been implemented so far:
* Fully re-written GUI with [Smarty][2] templates * Fully re-written GUI with [Smarty][2] templates
* Mobile WebUI * Mobile WebUI
* **NEW** VARDIFF Support * Scrypt, **NEW** SHA256, VARDIFF Support
* Reward Systems * Reward Systems
* Propotional * Propotional
* PPS * PPS
* PPLNS * PPLNS
* Statistics are cached in Memcache by Cronjob for quick data access * Statistics are cached in Memcache by Cronjob for quick data access
* **NEW** New Theme * New Theme
* **NEW** Live Dashboard * Live Dashboard
* **NEW** AJAX Support * AJAX Support
* **NEW** Overhauled API * Overhauled API
* Web User accounts * Web User accounts
* Re-Captcha protected registration form * Re-Captcha protected registration form
* Worker accounts * Worker accounts
@ -143,6 +141,15 @@ Other customizations are also possible but will require merging changes together
on non-existing features in `MPOS`. For the vast majority, adjusting themes should be enough to highlight your pool from others. on non-existing features in `MPOS`. For the vast majority, adjusting themes should be enough to highlight your pool from others.
In all that, I humbly ask to keep the `MPOS` author reference and Github URL intact. In all that, I humbly ask to keep the `MPOS` author reference and Github URL intact.
Related Software
================
There are a few other projects out there that take advantage of MPOS and it's included API. Here a quick list that you can check out for yourself:
* [MPOS IRC Bot](https://github.com/WKNiGHT-/mpos-bot) written in Python, standlone bot, using the MPOS API
* [MPOS Eggdrop Module](https://github.com/iAmShorty/mpos-eggdrop-tcl) written in TCL, adding MPOS commands to this bot, using the MPOS API
Contributing Contributing
============ ============

View File

@ -69,6 +69,24 @@ $config['wallet']['host'] = 'localhost:19334';
$config['wallet']['username'] = 'testnet'; $config['wallet']['username'] = 'testnet';
$config['wallet']['password'] = 'testnet'; $config['wallet']['password'] = 'testnet';
/**
* Getting Started Config
*
* This is displayed on GettingStarted Page
* to make it more dynamic
*
*
**/
$config['gettingstarted']['coinname'] = 'Litecoin';
$config['gettingstarted']['coinurl'] = 'http://www.litecoin.org';
$config['gettingstarted']['stratumport'] = '3333';
/** /**
* API configuration to fetch prices for set currency * API configuration to fetch prices for set currency
* *

View File

@ -4,6 +4,10 @@
if (!defined('SECURITY')) if (!defined('SECURITY'))
die('Hacking attempt'); die('Hacking attempt');
$smarty->assign("SITESTRATUMPORT", $config['gettingstarted']['stratumport']);
$smarty->assign("SITECOINNAME", $config['gettingstarted']['coinname']);
$smarty->assign("SITECOINURL", $config['gettingstarted']['coinurl']);
// Tempalte specifics // Tempalte specifics
$smarty->assign("CONTENT", "default.tpl"); $smarty->assign("CONTENT", "default.tpl");
?> ?>

View File

@ -7,9 +7,9 @@
</li> </li>
<li>2. <strong>Download a miner.</strong> <li>2. <strong>Download a miner.</strong>
<ul> <ul>
<li><em>Windows:</em> <a href="http://ck.kolivas.org/apps/cgminer/3.4/cgminer-3.4.3-windows.zip">Cgminer for Windows</a></li> <li><em>CGMiner Linux/Windows:</em> <a href="http://ck.kolivas.org/apps/cgminer/" target="_blank">Download here</a></li>
<li><em>Linux:</em> <a href="http://ck.kolivas.org/apps/cgminer/3.4/cgminer-3.4.3-x86_64-built.tar.bz2">Cgminer for Linux (64bit)</a></li> <li><em>CGMiner Mac OS X:</em> <a href="http://spaceman.ca/cgminer/" target="_blank">Download here</a></li>
<li><em>Mac OS X:</em> precompiled binaries are available <a href="https://bitcointalk.org/index.php?topic=55038.msg654850#msg654850">here</a>.</li> <li><em>CPU Miner Mac/Linux/Windows:</em> precompiled binaries are available <a href="https://bitcointalk.org/index.php?topic=55038.msg654850#msg654850" target="_blank">Download here</a>.</li>
</ul> </ul>
</li> </li>
<li>3. <strong>Configure your miner.</strong> <li>3. <strong>Configure your miner.</strong>
@ -17,29 +17,29 @@
<table width="50%"> <table width="50%">
<tbody> <tbody>
<tr><td>STRATUM:</td><td><kbd>stratum+tcp://{$smarty.server.SERVER_NAME}</kbd></td></tr> <tr><td>STRATUM:</td><td><kbd>stratum+tcp://{$smarty.server.SERVER_NAME}</kbd></td></tr>
<tr><td>PORT:</td><td><kbd>3333</kbd></td></tr> <tr><td>PORT:</td><td><kbd>{$SITESTRATUMPORT|default:"3333"}</kbd></td></tr>
<tr><td>Username:</td><td><kbd><em>Weblogin</em>.<em>Worker</em></kbd></td></tr> <tr><td>Username:</td><td><kbd><em>Weblogin</em>.<em>Worker</em></kbd></td></tr>
<tr><td>Password:</td><td><kbd>Worker Password</kbd></td></tr> <tr><td>Password:</td><td><kbd>Worker Password</kbd></td></tr>
</tbody> </tbody>
</table> </table>
<p>If you use a command-line miner, type:</p> <p>If you use a command-line miner, type:</p>
<pre>./cgminer --scrypt -o stratum+tcp://{$smarty.server.SERVER_NAME}:3333 -u <em>Weblogin</em>.<em>Worker</em> -p <em>Worker password</em></pre> <pre>./cgminer --scrypt -o stratum+tcp://{$smarty.server.SERVER_NAME}:{$SITESTRATUMPORT|default:"3333"} -u <em>Weblogin</em>.<em>Worker</em> -p <em>Worker password</em></pre>
<p>If you want, you can create additional workers with usernames and passwords of your choice <a href="{$smarty.server.PHP_SELF}?page=account&action=workers">Here</a></p> <p>If you want, you can create additional workers with usernames and passwords of your choice <a href="{$smarty.server.PHP_SELF}?page=account&action=workers">Here</a></p>
</li> </li>
<li>4. <strong>Create a Litecoin address to recieve payments.</strong> <li>4. <strong>Create a {$SITECOINNAME|default:"Litecoin"} address to recieve payments.</strong>
<ul> <ul>
<li> Downloading the client &amp; block chain: Download the Litecoin client from the <a href="http://www.litecoin.org/">here</a>. <li> Downloading the client &amp; block chain: Download the {$SITECOINNAME|default:"Litecoin"} client from the <a href="{$SITECOINURL|default:"http://www.litecoin.org"}" target="_blank">here</a>.
<p>Generate a new address and input it on your account page to receive payments.</p> <p>Generate a new address and input it on your account page to receive payments.</p>
</li> </li>
</ul> </ul>
</li> </li>
<li>5. <strong>Advanced cgminer settings / FAQ</strong> <li>5. <strong>Advanced cgminer settings / FAQ</strong>
<ul> <ul>
<li><a href="https://github.com/ckolivas/cgminer/blob/master/SCRYPT-README">Scrypt readme</a></li> <li><a href="https://github.com/ckolivas/cgminer/blob/master/SCRYPT-README" target="_blank">Scrypt readme</a></li>
<li>Don't set <b>intensity</b> too high, I=11 is standard and safest. Higher intensity takes more GPU RAM. Check for <b>hardware errors</b> in cgminer (HW). HW=0 is good, otherwise lower intensity :)</li> <li>Don't set <b>intensity</b> too high, I=11 is standard and safest. Higher intensity takes more GPU RAM. Check for <b>hardware errors</b> in cgminer (HW). HW=0 is good, otherwise lower intensity :)</li>
<li>Set shaders according to the readme (or look at your graphic cards specifications). Cgminer uses this value at first run to calculate <b>thread-concurrency</b>. Easiest way to get this optimized is to use same settings as others have used here: <a href="http://litecoin.info/Mining_Hardware_Comparison">here</a>.</li> <li>Set shaders according to the readme (or look at your graphic cards specifications). Cgminer uses this value at first run to calculate <b>thread-concurrency</b>. Easiest way to get this optimized is to use same settings as others have used here: <a href="http://litecoin.info/Mining_Hardware_Comparison">here</a>.</li>
<li>There's also an interesting project which gives you a GUI for cgminer. Windows only it seems.</li> <li>There's also an interesting project which gives you a GUI for cgminer. Windows only it seems.</li>
<li>Here's a great <a href="https://docs.google.com/document/d/1Gw7YPYgMgNNU42skibULbJJUx_suP_CpjSEdSi8_z9U/preview?sle=true">guide</a> how to get up and running with Xubuntu.</li> <li>Here's a great <a href="https://docs.google.com/document/d/1Gw7YPYgMgNNU42skibULbJJUx_suP_CpjSEdSi8_z9U/preview?sle=true" target="_blank">guide</a> how to get up and running with Xubuntu.</li>
</ul> </ul>
</li> </li>
{include file="global/block_footer.tpl"} {include file="global/block_footer.tpl"}

View File

@ -20,7 +20,7 @@
<td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td> <td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td>
<td class="right">{($CONTRIBHASHES[contrib].hashrate * $GLOBAL.hashmods.personal)|number_format:"2"}</td> <td class="right">{($CONTRIBHASHES[contrib].hashrate * $GLOBAL.hashmods.personal)|number_format:"2"}</td>
<td class="right">{$estday|number_format:"3"}</td> <td class="right">{$estday|number_format:"3"}</td>
{if $GLOBAL.config.price.currency}<td class="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td>{/if} {if $GLOBAL.config.price.currency}<td class="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>{/if}
</tr> </tr>
{/section} {/section}
{if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0} {if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0}
@ -30,7 +30,7 @@
<td>{$GLOBAL.userdata.username|escape}</td> <td>{$GLOBAL.userdata.username|escape}</td>
<td class="right">{$GLOBAL.userdata.hashrate}</td> <td class="right">{$GLOBAL.userdata.hashrate}</td>
<td class="right">{$myestday|number_format:"3"|default:"n/a"}</td> <td class="right">{$myestday|number_format:"3"|default:"n/a"}</td>
{if $GLOBAL.config.price.currency}<td class="right">{($myestday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td>{/if} {if $GLOBAL.config.price.currency}<td class="right">{($myestday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>{/if}
</tr> </tr>
{/if} {/if}
</tbody> </tbody>

View File

@ -19,7 +19,7 @@
<td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td> <td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td>
<td align="right">{$CONTRIBHASHES[contrib].hashrate|number_format}</td> <td align="right">{$CONTRIBHASHES[contrib].hashrate|number_format}</td>
<td align="right">{$estday|number_format:"3"}</td> <td align="right">{$estday|number_format:"3"}</td>
<td align="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td> <td align="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>
</tr> </tr>
{/section} {/section}
{if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0} {if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0}
@ -28,7 +28,7 @@
<td>{$GLOBAL.userdata.username}</td> <td>{$GLOBAL.userdata.username}</td>
<td align="right">{$GLOBAL.userdata.hashrate}</td> <td align="right">{$GLOBAL.userdata.hashrate}</td>
<td align="right">{$estday|number_format:"3"|default:"n/a"}</td> <td align="right">{$estday|number_format:"3"|default:"n/a"}</td>
<td align="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td> <td align="right">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>
</tr> </tr>
{/if} {/if}
</tbody> </tbody>

View File

@ -9,9 +9,9 @@
</li> </li>
<li>2. <strong>Download a miner.</strong> <li>2. <strong>Download a miner.</strong>
<ul> <ul>
<li><em>Windows:</em> <a href="http://ck.kolivas.org/apps/cgminer/3.4/cgminer-3.4.3-windows.zip">Cgminer for Windows</a></li> <li><em>CGMiner Linux/Windows:</em> <a href="http://ck.kolivas.org/apps/cgminer/" target="_blank">Download here</a></li>
<li><em>Linux:</em> <a href="http://ck.kolivas.org/apps/cgminer/3.4/cgminer-3.4.3-x86_64-built.tar.bz2">Cgminer for Linux (64bit)</a></li> <li><em>CGMiner Mac OS X:</em> <a href="http://spaceman.ca/cgminer/" target="_blank">Download here</a></li>
<li><em>Mac OS X:</em> precompiled binaries are available <a href="https://bitcointalk.org/index.php?topic=55038.msg654850#msg654850">here</a>.</li> <li><em>CPU Miner Mac/Linux/Windows:</em> precompiled binaries are available <a href="https://bitcointalk.org/index.php?topic=55038.msg654850#msg654850" target="_blank">Download here</a>.</li>
</ul> </ul>
</li> </li>
<li>3. <strong>Configure your miner.</strong> <li>3. <strong>Configure your miner.</strong>
@ -19,29 +19,29 @@
<table width="50%"> <table width="50%">
<tbody> <tbody>
<tr><td>STRATUM:</td><td><kbd>stratum+tcp://{$smarty.server.SERVER_NAME}</kbd></td></tr> <tr><td>STRATUM:</td><td><kbd>stratum+tcp://{$smarty.server.SERVER_NAME}</kbd></td></tr>
<tr><td>PORT:</td><td><kbd>3333</kbd></td></tr> <tr><td>PORT:</td><td><kbd>{$SITESTRATUMPORT|default:"3333"}</kbd></td></tr>
<tr><td>Username:</td><td><kbd><em>Weblogin</em>.<em>Worker</em></kbd></td></tr> <tr><td>Username:</td><td><kbd><em>Weblogin</em>.<em>Worker</em></kbd></td></tr>
<tr><td>Password:</td><td><kbd>Worker Password</kbd></td></tr> <tr><td>Password:</td><td><kbd>Worker Password</kbd></td></tr>
</tbody> </tbody>
</table> </table>
<p>If you use a command-line miner, type:</p> <p>If you use a command-line miner, type:</p>
<pre>./cgminer --scrypt -o stratum+tcp://{$smarty.server.SERVER_NAME}:3333 -u <em>Weblogin</em>.<em>Worker</em> -p <em>Worker password</em></pre> <pre>./cgminer --scrypt -o stratum+tcp://{$smarty.server.SERVER_NAME}:{$SITESTRATUMPORT|default:"3333"} -u <em>Weblogin</em>.<em>Worker</em> -p <em>Worker password</em></pre>
<p>If you want, you can create additional workers with usernames and passwords of your choice <a href="{$smarty.server.PHP_SELF}?page=account&action=workers">Here</a></p> <p>If you want, you can create additional workers with usernames and passwords of your choice <a href="{$smarty.server.PHP_SELF}?page=account&action=workers">Here</a></p>
</li> </li>
<li>4. <strong>Create a Litecoin address to recieve payments.</strong> <li>4. <strong>Create a {$SITECOINNAME|default:"Litecoin"} address to recieve payments.</strong>
<ul> <ul>
<li> Downloading the client &amp; block chain: Download the Litecoin client from the <a href="http://www.litecoin.org/">here</a>. <li> Downloading the client &amp; block chain: Download the {$SITECOINNAME|default:"Litecoin"} client from <a href="{$SITECOINURL|default:"http://www.litecoin.org"}" target="_blank">here</a>.
<p>Generate a new address and input it on your account page to receive payments.</p> <p>Generate a new address and input it on your account page to receive payments.</p>
</li> </li>
</ul> </ul>
</li> </li>
<li>5. <strong>Advanced cgminer settings / FAQ</strong> <li>5. <strong>Advanced cgminer settings / FAQ</strong>
<ul> <ul>
<li><a href="https://github.com/ckolivas/cgminer/blob/master/SCRYPT-README">Scrypt readme</a></li> <li><a href="https://github.com/ckolivas/cgminer/blob/master/SCRYPT-README" target="_blank">Scrypt readme</a></li>
<li>Don't set <b>intensity</b> too high, I=11 is standard and safest. Higher intensity takes more GPU RAM. Check for <b>hardware errors</b> in cgminer (HW). HW=0 is good, otherwise lower intensity :)</li> <li>Don't set <b>intensity</b> too high, I=11 is standard and safest. Higher intensity takes more GPU RAM. Check for <b>hardware errors</b> in cgminer (HW). HW=0 is good, otherwise lower intensity :)</li>
<li>Set shaders according to the readme (or look at your graphic cards specifications). Cgminer uses this value at first run to calculate <b>thread-concurrency</b>. Easiest way to get this optimized is to use same settings as others have used here: <a href="http://litecoin.info/Mining_Hardware_Comparison">here</a>.</li> <li>Set shaders according to the readme (or look at your graphic cards specifications). Cgminer uses this value at first run to calculate <b>thread-concurrency</b>. Easiest way to get this optimized is to use same settings as others have used here: <a href="http://litecoin.info/Mining_Hardware_Comparison">here</a>.</li>
<li>There's also an interesting project which gives you a GUI for cgminer. Windows only it seems.</li> <li>There's also an interesting project which gives you a GUI for cgminer. Windows only it seems.</li>
<li>Here's a great <a href="https://docs.google.com/document/d/1Gw7YPYgMgNNU42skibULbJJUx_suP_CpjSEdSi8_z9U/preview?sle=true">guide</a> how to get up and running with Xubuntu.</li> <li>Here's a great <a href="https://docs.google.com/document/d/1Gw7YPYgMgNNU42skibULbJJUx_suP_CpjSEdSi8_z9U/preview?sle=true" target="_blank">guide</a> how to get up and running with Xubuntu.</li>
</ul> </ul>
</li> </li>
</div> </div>

View File

@ -23,7 +23,7 @@
<td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td> <td>{if $CONTRIBHASHES[contrib].is_anonymous|default:"0" == 1 && $GLOBAL.userdata.is_admin|default:"0" == 0}anonymous{else}{$CONTRIBHASHES[contrib].account|escape}{/if}</td>
<td align="right">{$CONTRIBHASHES[contrib].hashrate|number_format}</td> <td align="right">{$CONTRIBHASHES[contrib].hashrate|number_format}</td>
<td align="right">{$estday|number_format:"3"}</td> <td align="right">{$estday|number_format:"3"}</td>
{if $GLOBAL.config.price.currency}<td align="right" style="padding-right: 25px;">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td>{/if} {if $GLOBAL.config.price.currency}<td align="right" style="padding-right: 25px;">{($estday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>{/if}
</tr> </tr>
{/section} {/section}
{if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0} {if $listed != 1 && $GLOBAL.userdata.username|default:"" && $GLOBAL.userdata.hashrate|default:"0" > 0}
@ -34,7 +34,7 @@
<td>{$GLOBAL.userdata.username|escape}</td> <td>{$GLOBAL.userdata.username|escape}</td>
<td align="right">{$GLOBAL.userdata.hashrate}</td> <td align="right">{$GLOBAL.userdata.hashrate}</td>
<td align="right">{$myestday|number_format:"3"|default:"n/a"}</td> <td align="right">{$myestday|number_format:"3"|default:"n/a"}</td>
{if $GLOBAL.config.price.currency}<td align="right" style="padding-right: 25px;">{($myestday * $GLOBAL.price)|default:"n/a"|number_format:"2"}</td>{/if} {if $GLOBAL.config.price.currency}<td align="right" style="padding-right: 25px;">{($myestday * $GLOBAL.price)|default:"n/a"|number_format:"4"}</td>{/if}
</tr> </tr>
{/if} {/if}
</tbody> </tbody>