Move RPC login to a Secret, put P2Pool on a selectable sidechain

The monerod RPC login was in both Deployments' args, readable by anyone who
can read Deployments. It now lives in the monerod-rpc Secret and reaches the
containers through an env var.

P2Pool now runs on monero_p2pool_chain, defaulting to nano. On main the
miners found a share about every 6 days and missed most PPLNS windows.
The hardcoded main-chain peer only applied to main, so peers are a variable.

monerod's RPC SSL is now autodetect: Shkeeper's Monero module always uses
plain HTTP, so with SSL required it saw the node as Offline and hid XMR.

Also: Deployments use apps/v1, monerod's ZMQ binds 0.0.0.0 to match the
live deployment (P2Pool connects from its own pod), required variables are
checked up front, and the README describes the role.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-07 11:46:16 -05:00
co-authored by Claude Opus 5.5
parent dfef5bea63
commit 46aec42185
3 changed files with 98 additions and 46 deletions
+23 -22
View File
@@ -1,38 +1,39 @@
Role Name
=========
ansible-role-monero
===================
A brief description of the role goes here.
Requirements
------------
Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required.
Deploys a Monero node (monerod) and a P2Pool node to Kubernetes, in the
`monero` namespace. Miners point xmrig at the P2Pool service on port 3333.
Role Variables
--------------
A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well.
Required, from Vault:
Dependencies
------------
- `monerod_user`, `monerod_password`: monerod's RPC login. Stored in the
`monerod-rpc` Secret and passed to both containers through an environment
variable, so it doesn't show in the Deployment specs.
- `monero_p2pool_wallet_address`: the address P2Pool pays out to.
A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles.
Optional:
- `monero_p2pool_chain` (default `nano`): `main`, `mini` or `nano`. Match it
to your total hashrate; see the note in `defaults/main.yml`. Switching
chains starts from zero shares on the new chain, and shares on the old one
stop earning once they leave its PPLNS window.
- `monero_p2pool_addpeers` (default `[]`): extra P2Pool peers as `host:port`.
They must be on the same chain.
Example Playbook
----------------
Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:
- hosts: servers
- hosts: alpha-control-plane
become: true
vars_files:
- ../secrets.yaml
roles:
- { role: username.rolename, x: 42 }
- role: ericomeehan.monero
License
-------
BSD
Author Information
------------------
An optional section for the role authors to include contact information, or a website (HTML is not allowed).
MIT-0