mirror of
https://github.com/Such-Software/xmrcheckout.git
synced 2026-10-17 05:51:34 +02:00
Add local monerod docker compose profile
This commit is contained in:
@@ -21,6 +21,10 @@ MONERO_WALLET_RPC_USER=
|
||||
MONERO_WALLET_RPC_PASSWORD=
|
||||
MONERO_WALLET_RPC_WALLET_PASSWORD=
|
||||
MONERO_WALLET_RPC_WALLET_DIR=/wallets
|
||||
|
||||
# Monero daemon
|
||||
# - Default: uses a third-party daemon (low setup, external dependency)
|
||||
# - Local: run the bundled `monerod` service and set MONERO_DAEMON_URL=http://monerod:18081
|
||||
MONERO_DAEMON_URL=http://xmr-node.cakewallet.com:18081
|
||||
|
||||
# UI
|
||||
|
||||
@@ -76,21 +76,35 @@ cp .env.example .env
|
||||
- `POSTGRES_USER`, `POSTGRES_PASSWORD`, `POSTGRES_DB`
|
||||
- `API_KEYS`, `API_KEY_ENCRYPTION_KEY`
|
||||
- `SITE_URL` (public URL for the UI)
|
||||
- Monero view-only wallet settings (`MONERO_WALLET_RPC_*`) and daemon URL
|
||||
- `MONERO_DAEMON_URL` if you use your own daemon
|
||||
- Monero view-only wallet settings (`MONERO_WALLET_RPC_*`)
|
||||
- `MONERO_DAEMON_URL` (choose one of the options below)
|
||||
|
||||
3. Choose a wallet-rpc target and provision view-only wallets:
|
||||
3. Choose a Monero daemon source:
|
||||
- **Use a third-party daemon (default):**
|
||||
- Leave `MONERO_DAEMON_URL` as-is (the default points at a public Monero daemon).
|
||||
- **Run your own daemon via Docker Compose:**
|
||||
- Set `MONERO_DAEMON_URL=http://monerod:18081`
|
||||
- Start the stack with the `local-daemon` profile (see step 5)
|
||||
- Note: initial sync can take a long time and uses significant disk; payment detection won’t be reliable until the daemon is synced.
|
||||
|
||||
4. Choose a wallet-rpc target and provision view-only wallets:
|
||||
- Use the bundled wallet-rpc containers:
|
||||
- Set `MONERO_WALLET_RPC_URLS=http://wallet-rpc-reconciler-1:18083,http://wallet-rpc-reconciler-2:18083,http://wallet-rpc-reconciler-3:18083`
|
||||
- Or point to an external wallet-rpc service:
|
||||
- Set `MONERO_WALLET_RPC_URLS`, `MONERO_WALLET_RPC_USER`, `MONERO_WALLET_RPC_PASSWORD`, and `MONERO_WALLET_RPC_WALLET_PASSWORD`
|
||||
|
||||
4. Start the stack:
|
||||
5. Start the stack:
|
||||
|
||||
```
|
||||
docker compose up --build -d
|
||||
```
|
||||
|
||||
If you’re running the bundled `monerod` service:
|
||||
|
||||
```
|
||||
docker compose --profile local-daemon up --build -d
|
||||
```
|
||||
|
||||
### Optional: donations (disabled by default)
|
||||
|
||||
Donation endpoints and UI are off by default for self-hosted deployments.
|
||||
|
||||
@@ -64,6 +64,37 @@ services:
|
||||
db:
|
||||
condition: service_healthy
|
||||
restart: on-failure
|
||||
monerod:
|
||||
build:
|
||||
context: ./docker/monero
|
||||
args:
|
||||
MONERO_VERSION: ${MONERO_VERSION:-0.18.4.4}
|
||||
image: monero-local:${MONERO_VERSION:-0.18.4.4}
|
||||
entrypoint: ["monerod"]
|
||||
command:
|
||||
[
|
||||
"--non-interactive",
|
||||
"--rpc-bind-ip",
|
||||
"0.0.0.0",
|
||||
"--rpc-bind-port",
|
||||
"18081",
|
||||
"--confirm-external-bind",
|
||||
"--prune-blockchain",
|
||||
"--data-dir",
|
||||
"/data",
|
||||
"--log-level",
|
||||
"0"
|
||||
]
|
||||
volumes:
|
||||
- monerod_data:/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "curl -fsS http://127.0.0.1:18081/get_height >/dev/null || exit 1"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 10
|
||||
start_period: 60s
|
||||
restart: on-failure
|
||||
profiles: ["local-daemon"]
|
||||
wallet-rpc-reconciler-1:
|
||||
build:
|
||||
context: ./docker/monero
|
||||
@@ -187,3 +218,4 @@ services:
|
||||
retries: 10
|
||||
volumes:
|
||||
postgres_data:
|
||||
monerod_data:
|
||||
|
||||
Reference in New Issue
Block a user