diff --git a/CHANGELOG.md b/CHANGELOG.md index eef2d572..b3309bc9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,22 @@ -## Changed (2025-09-08) +## Changed (2025-09-10) # Changelog - 4NK Node +## [1.1.4-wip.1] - 2025-09-10 + +### Changed +- docker-compose.yml: qualification des images 4NK vers `git.4nkweb.com` (ihm_client, sdk_storage, sdk_signer, blindbit-oracle, lecoffre-*). +- docker-compose.yml: remplacement de Tor par `dperson/torproxy:latest`. +- docker-compose.yml: unification des relais `sdk_relay1/2/3` sur l’image unique `git.4nkweb.com/4nk/sdk_relay:dev`. +- docker-compose.yml: correction des chemins `modules/blindbit-oracle/*` et des noms `*oracle`. + +### Documentation +- DEPLOYMENT.md: mise à jour des images, ports, services, procédures (copie des `*.exemple`). +- CONFIGURATION.md: mise à jour de la politique de tags et procédures usuelles. + +### Fixed +- Démarrage bloqué par montage `tor.conf` (répertoire créé par erreur): régularisation en fichier + copie depuis `.exemple`. + +--- ## [1.1.3] - 2025-09-07 ### Added diff --git a/VERSION b/VERSION index 99a4aef0..79d6cbfb 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v1.1.3 +v1.1.4-wip.1 diff --git a/docker-compose.yml b/docker-compose.yml index 4e62de48..a83439af 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -4,7 +4,7 @@ version: '3.8' services: tor: - image: torproject/tor:latest + image: dperson/torproxy:latest container_name: 4nk-tor hostname: tor.4nk.local ports: @@ -39,9 +39,9 @@ services: - tor blindbit: - image: 4nk-node-blindbit:latest - container_name: 4nk-blindbit - hostname: blindbit.4nk.local + image: git.4nkweb.com/4nk/blindbit-oracle:dev + container_name: 4nk-blindbit-oracle + hostname: blindbit-oracle.4nk.local ports: - "8000:8000" @@ -58,9 +58,9 @@ services: command: [ "/main", "--datadir", "/blindbit" ] working_dir: / volumes: - - ./modules/blindbit/conf/blindbit.toml:/blindbit/blindbit.toml:ro - - ./modules/blindbit/data:/blindbit - - ./modules/blindbit/logs:/blindbit/logs + - ./modules/blindbit-oracle/conf/blindbit.toml:/blindbit/blindbit.toml:ro + - ./modules/blindbit-oracle/data:/blindbit + - ./modules/blindbit-oracle/logs:/blindbit/logs networks: 4nk_network: ipv4_address: 172.20.0.12 @@ -75,7 +75,7 @@ services: start_period: 40s sdk_storage: - image: 4nk-node-sdk_storage:dev + image: git.4nkweb.com/4nk/sdk_storage:dev container_name: 4nk-sdk-storage hostname: sdk-storage.4nk.local ports: @@ -95,7 +95,7 @@ services: start_period: 40s sdk_relay1: - image: 4nk-node-sdk_relay1:dev + image: git.4nkweb.com/4nk/sdk_relay:dev container_name: 4nk-sdk-relay1 hostname: sdk-relay1.4nk.local ports: @@ -122,7 +122,7 @@ services: start_period: 40s sdk_relay2: - image: 4nk-node-sdk_relay2:dev + image: git.4nkweb.com/4nk/sdk_relay:dev container_name: 4nk-sdk-relay2 hostname: sdk-relay2.4nk.local ports: @@ -149,7 +149,7 @@ services: start_period: 40s sdk_relay3: - image: 4nk-node-sdk_relay3:dev + image: git.4nkweb.com/4nk/sdk_relay:dev container_name: 4nk-sdk-relay3 hostname: sdk-relay3.4nk.local ports: @@ -176,7 +176,7 @@ services: start_period: 40s sdk_signer: - image: 4nk-node-sdk_signer:dev + image: git.4nkweb.com/4nk/sdk_signer:dev container_name: 4nk-sdk-signer hostname: sdk-signer.4nk.local ports: @@ -202,7 +202,7 @@ services: start_period: 40s ihm_client: - image: 4nk-node-ihm_client:dev + image: git.4nkweb.com/4nk/ihm_client:dev container_name: 4nk-ihm-client hostname: ihm-client.4nk.local ports: @@ -244,7 +244,7 @@ services: - "5432:5432" coffre_front: - image: lecoffre-front:dev + image: git.4nkweb.com/4nk/lecoffre-front:dev container_name: coffre-front hostname: coffre-front.4nk.local volumes: @@ -259,7 +259,7 @@ services: - sdk_signer coffre_back_mini: - image: lecoffre-back-mini:dev + image: git.4nkweb.com/4nk/lecoffre-back-mini:dev container_name: coffre-back-mini hostname: coffre-back-mini.4nk.local networks: diff --git a/docs/CONFIGURATION.md b/docs/CONFIGURATION.md index ba73200c..db75d884 100644 --- a/docs/CONFIGURATION.md +++ b/docs/CONFIGURATION.md @@ -1,10 +1,12 @@ ## Configuration des images, réseaux et paramètres -### Politique de tags +### Politique de tags et registres -- Référence locale : tags internes `:dev` (services 4NK) utilisés par défaut dans `docker-compose.yml`. -- Images externes stables : `torproject/tor:latest`, `ruimarinho/bitcoin-core:latest`, `4nk-node-blindbit:latest`. -- Alignement documentaire : la stratégie `:dev` est retenue pour cet environnement. Aucune modification de fichiers de configuration n’est effectuée par ce document. +- Référence: les services 4NK tirent les images `:dev` depuis `git.4nkweb.com`. +- Images externes stables: `dperson/torproxy:latest`, `ruimarinho/bitcoin-core:latest`. +- Blindbit: `git.4nkweb.com/4nk/blindbit-oracle:dev`. +- Relais: `git.4nkweb.com/4nk/sdk_relay:dev` (image unique pour 1/2/3). +- Signer/Storage/UI/Coffre: images `git.4nkweb.com/4nk/*:dev`. ### Réseaux et adresses @@ -39,11 +41,12 @@ Nota : ces variables sont documentées pour référence et ne modifient pas la - Nginx agit en reverse‑proxy et expose des routes stables : `/`, `/blindbit/`, `/sdk_storage/`, `/relay1|2|3/` (+ `/ws/`), `/signer/` (+ `/ws/`), `/coffre/`, `/grafana/`. - L’exécution locale (hors Docker) est supportée ; les fichiers de configuration existants ne sont pas modifiés par ce document. -### Procédures usuelles (sans modification de conf) +### Procédures usuelles -- Vérifier les images : `docker compose pull`. -- Démarrer la stack : `docker compose up -d` (ou exécutions locales pour Nginx/Grafana, selon `USAGE.md`). -- Consulter les logs : via `docker compose logs` ou les fichiers montés. +- Initialiser les configurations: copier tous les fichiers `*.exemple` vers leur homonyme sans suffixe. +- Vérifier les images : `docker-compose pull`. +- Démarrer la stack : `docker-compose up -d`. +- Consulter les logs : `docker-compose logs --tail=100`. ### Conclusion diff --git a/docs/DEPLOYMENT.md b/docs/DEPLOYMENT.md index 91c199fe..57ff4ce2 100644 --- a/docs/DEPLOYMENT.md +++ b/docs/DEPLOYMENT.md @@ -3,16 +3,29 @@ ## Docker ### Images et tags -- tor: 4nk-node-tor:latest -- bitcoin: 4nk-node-bitcoin:latest +- tor: dperson/torproxy:latest +- bitcoin: ruimarinho/bitcoin-core:latest +- blindbit: git.4nkweb.com/4nk/blindbit-oracle:dev +- sdk_storage: git.4nkweb.com/4nk/sdk_storage:dev +- sdk_signer: git.4nkweb.com/4nk/sdk_signer:dev +- sdk_relay1/2/3: git.4nkweb.com/4nk/sdk_relay:dev (image unique) +- ihm_client: git.4nkweb.com/4nk/ihm_client:dev +- coffre_back_mini: git.4nkweb.com/4nk/lecoffre-back-mini:dev +- coffre_front: git.4nkweb.com/4nk/lecoffre-front:dev ### docker-compose - Fichier: 4NK_node/docker-compose.yml - Services: - - tor: ports 9050, 9051; volume tor_data; conf conf/tor.conf - - bitcoin: ports 38333, 18443, 29000; volume bitcoin_data; conf conf/bitcoin.conf; dépend de tor + - tor: ports 9050, 9051; conf optionnelle `modules/tor/conf/tor.conf` (copiée depuis `.exemple`) + - bitcoin: ports 38333, 38332, 29000; volumes `modules/bitcoin/{data,logs}`; conf `modules/bitcoin/conf/bitcoin.conf`; dépend de tor + - blindbit: port 8000; conf `modules/blindbit-oracle/conf/blindbit.toml`; dépend de bitcoin + - sdk_storage: port 8081 + - sdk_relay1/2/3: ports 8090/8091 + - sdk_signer: port 9090 + - ihm_client: ports 8080/3003 + - miniback-postgres: port 5432 - Réseau: 4nk_network (bridge) -- Volumes nommés: tor_data, bitcoin_data +- Volumes nommés: miniback_pg_data ## Intégration dans 4NK_node - Configuration centralisée dans 4NK_node/conf/ (ex: bitcoin.conf, tor.conf). @@ -20,21 +33,31 @@ - Modules complémentaires (ihm_client, sdk_relay, sdk_storage, sdk_signer) s’intègrent via 4NK_node/modules/ et le réseau Docker partagé. ## CI/CD appliquée -- Construire les images avec le tag dédié docker-support-v2 selon la politique du projet. -- Valider les builds et la santé (healthchecks) avant déploiement. -- Publier les artefacts et images dans le registre interne si applicable. +- Les services 4NK tirent les images `:dev` depuis `git.4nkweb.com`. +- Valider les healthchecks (wget sur ports exposés) avant déploiement. +- Publier les images sur `git.4nkweb.com` pour toute mise à jour. ## Configuration ### Variables d’environnement - Gérées au niveau des services consommateurs (ex: ihm_client, sdk_*). -### Fichiers de configuration (4NK_node/conf) -- bitcoin.conf (Bitcoin Core) -- tor.conf (Tor) -- Fichiers spécifiques modules: sdk_relay*.conf, sdk_signer.conf, sdk_storage.conf, ihm_client.conf, nginx.conf +### Fichiers de configuration (4NK_node/conf et modules/*/conf) +- `modules/bitcoin/conf/bitcoin.conf` +- `modules/tor/conf/tor.conf` (copier depuis `tor.conf.exemple` si absent) +- `modules/blindbit-oracle/conf/blindbit.toml` +- `modules/sdk_relay{1,2,3}/conf/sdk_relay*.conf` +- `modules/sdk_signer/conf/.env` +- `modules/sdk_storage/conf/sdk_storage.conf` +- `modules/ihm_client/conf/.env` +- `conf/nginx/nginx.conf`, `conf/nginx/sites-enabled/4nk_node.conf` ### Réseau et ports - tor: 9050 (SOCKS), 9051 (Control) -- bitcoin: 38333 (P2P testnet/regtest), 18443 (RPC), 29000 (custom) +- bitcoin: 38333 (P2P signet), 38332 (RPC), 29000 (custom) +- blindbit: 8000 +- sdk_storage: 8081 +- sdk_relay: 8090/8091 +- sdk_signer: 9090 +- ihm_client: 8080/3003 diff --git a/modules/blindbit/conf/blindbit.toml.exemple b/modules/blindbit-oracle/conf/blindbit.toml.exemple similarity index 100% rename from modules/blindbit/conf/blindbit.toml.exemple rename to modules/blindbit-oracle/conf/blindbit.toml.exemple diff --git a/modules/blindbit/data/.gitkeep b/modules/blindbit-oracle/data/.gitkeep similarity index 100% rename from modules/blindbit/data/.gitkeep rename to modules/blindbit-oracle/data/.gitkeep diff --git a/modules/blindbit/logs/.gitkeep b/modules/blindbit-oracle/logs/.gitkeep similarity index 100% rename from modules/blindbit/logs/.gitkeep rename to modules/blindbit-oracle/logs/.gitkeep diff --git a/modules/blindbit/conf/blindbit.toml b/modules/blindbit/conf/blindbit.toml deleted file mode 100644 index 1968aa40..00000000 --- a/modules/blindbit/conf/blindbit.toml +++ /dev/null @@ -1,50 +0,0 @@ -# 0.0.0.0:8000 to expose outside of localhost -# default: "127.0.0.1:8000" -host="blindbit.4nk.local:8000" - -# Defines on which chain the wallet runs. Allowed values: main, testnet, signet, regtest. -# default: signet -chain="signet" - -# default: http://bitcoin.4nk.local:8332 -rpc_endpoint="http://bitcoin.4nk.local:38332" - -# required, unless rpc_user and rpc_pass are set -cookie_path="/home/bitcoin/.bitcoin/signet/.cookie" - -# required, unless cookie_path is set -rpc_pass="" - -# required, unless cookie_path is set -rpc_user="" - -# required (has to be >= 1) -sync_start_height=1 - -# the default for this is 1, but should be set to a higher value to increase performance, -# one should set this in accordance to how many cores one wants to use -max_parallel_tweak_computations=4 - -# (depends on max-rpc-workers of the underlying full node) -max_parallel_requests=4 - -# optional - will only generate tweaks (still both cut-through and full-index) -# default: 0 -tweaks_only=0 - -# The base index. Only includes the tweaks. No dust filtering or cut-through possible -# default: 1 -tweaks_full_basic=1 - -# if this is set a full non-cut-through index will be created. -# This index can be used to filter for dust (?dustLimit=). If this is active the base index will not be created. -# All full index queries will be served from this with or without (?dustLimit=) set in the query. -# default 0 -tweaks_full_with_dust_filter=0 - -# This index applies cut-through and dust filtering. -# Beware that it will be stored in addition to any full index (with or without dust) if activated. -# It has more storage requirements than the simple indices. -# Currently still requires tweaks_only=0. -# default: 0 -tweaks_cut_through_with_dust_filter=0 \ No newline at end of file diff --git a/modules/sdk_signer/data/000005.ldb b/modules/sdk_signer/data/000005.ldb new file mode 100644 index 00000000..f34d321c Binary files /dev/null and b/modules/sdk_signer/data/000005.ldb differ diff --git a/modules/sdk_signer/data/CURRENT b/modules/sdk_signer/data/CURRENT new file mode 100644 index 00000000..1afa5d49 --- /dev/null +++ b/modules/sdk_signer/data/CURRENT @@ -0,0 +1 @@ +MANIFEST-000047 diff --git a/modules/sdk_signer/data/LOCK b/modules/sdk_signer/data/LOCK new file mode 100644 index 00000000..e69de29b diff --git a/modules/sdk_signer/data/LOG b/modules/sdk_signer/data/LOG new file mode 100644 index 00000000..9cd8bd7e --- /dev/null +++ b/modules/sdk_signer/data/LOG @@ -0,0 +1,3 @@ +2025/09/10-13:56:22.250730 7fdd3ec7cb38 Recovering log #46 +2025/09/10-13:56:22.264271 7fdd3ec7cb38 Delete type=0 #46 +2025/09/10-13:56:22.264303 7fdd3ec7cb38 Delete type=3 #45 diff --git a/modules/sdk_signer/data/LOG.old b/modules/sdk_signer/data/LOG.old new file mode 100644 index 00000000..13606d68 --- /dev/null +++ b/modules/sdk_signer/data/LOG.old @@ -0,0 +1,3 @@ +2025/09/10-13:55:50.937547 7f0fa344fb38 Recovering log #44 +2025/09/10-13:55:50.953834 7f0fa344fb38 Delete type=0 #44 +2025/09/10-13:55:50.953909 7f0fa344fb38 Delete type=3 #43 diff --git a/modules/sdk_signer/data/MANIFEST-000047 b/modules/sdk_signer/data/MANIFEST-000047 new file mode 100644 index 00000000..7ea8f69a Binary files /dev/null and b/modules/sdk_signer/data/MANIFEST-000047 differ