60 Commits

Author SHA1 Message Date
anonpenguin23
32470052ba
feat: enhance production command handling and configuration management
- Updated the production command to support dynamic IP address extraction from bootstrap peer multiaddrs, improving node connectivity.
- Refactored the configuration generation to include advertised HTTP and Raft addresses based on the node type and bootstrap peers.
- Enhanced error handling and logging for service management commands, ensuring better feedback during installation and upgrades.
- Improved the README documentation with new command examples and clarified usage instructions for production deployment.
2025-11-12 09:14:26 +02:00
anonpenguin23
52b3a99bb9
feat: add branch management for production commands
- Introduced `--branch` flag for specifying Git branches (main or nightly) during installation and upgrade processes.
- Implemented validation for branch input and defaulted to 'main' if not specified.
- Enhanced help output to include examples for using the new branch feature.
- Added functionality to save and read branch preferences for future upgrades, improving user experience and flexibility.
2025-11-11 08:45:20 +02:00
anonpenguin23
b896e37e09
fix: improve disk space check logic in ResourceChecker
- Updated CheckDiskSpace method to validate disk space against the parent directory if the specified path does not exist.
- Enhanced error handling to ensure accurate reporting of disk space validation failures.
2025-11-11 07:00:39 +02:00
anonpenguin23
badaa920d9
feat: enhance production command handling and configuration generation
- Added comprehensive tests for production command flag parsing to ensure correct handling of bootstrap, VPS IP, and peer configurations.
- Updated production command help output to clarify the usage of new flags, including `--vps-ip` and `--bootstrap-join`.
- Modified the configuration generation logic to incorporate the new `bootstrapJoin` parameter for secondary bootstrap nodes.
- Enhanced systemd service generation to include the correct advertise IP and join address for non-bootstrap nodes.
- Implemented tests for RQLite service generation to verify the inclusion of join addresses and advertise IPs in the generated units.
2025-11-11 06:51:28 +02:00
anonpenguin23
6a86592cad
refactor: streamline development and production command structure
- Consolidated development commands into a new `dev` command group for better organization.
- Introduced a `prod` command group to manage production environment operations.
- Updated Makefile to simplify the development environment setup and improve logging.
- Enhanced README to clarify the development process and health check requirements.
- Removed deprecated configuration and service management commands to streamline the CLI interface.
2025-11-10 05:34:50 +02:00
anonpenguin23
0388c3a766
refactor: streamline development and production command structure
- Consolidated development commands into a new `dev` command group for better organization.
- Introduced a `prod` command group to manage production environment operations.
- Updated Makefile to simplify the development environment setup and improve logging.
- Enhanced README to clarify the development process and health check requirements.
- Removed deprecated configuration and service management commands to streamline the CLI interface.
2025-11-09 18:28:24 +02:00
anonpenguin23
c726dfc401 feat: update IPFS configuration and enhance cluster secret management
- Changed default IPFS API URL to port 5001 for better compatibility.
- Enhanced the initialization process for IPFS and Cluster by adding support for bootstrap peers.
- Introduced user prompts for cluster secret and swarm key generation, improving user experience during setup.
- Updated service configuration to dynamically determine paths based on existing configuration files.
2025-11-08 13:29:21 +02:00
anonpenguin23
3196e91e85
feat: integrate Olric distributed cache support
- Added Olric cache server integration, including configuration options for Olric servers and timeout settings.
- Implemented HTTP handlers for cache operations: health check, get, put, delete, and scan.
- Enhanced Makefile with commands to run the Olric server and manage its configuration.
- Updated README and setup scripts to include Olric installation and configuration instructions.
- Introduced tests for cache handlers to ensure proper functionality and error handling.
2025-11-03 15:30:08 +02:00
anonpenguin23
8538e2eb3f feat: streamline Anon installation with automated terms acceptance
- Implemented pre-acceptance of Anon terms in both the setup and installation scripts to eliminate interactive prompts.
- Enhanced the installation process by creating necessary directories and files to ensure terms are accepted before installation.
- Updated the installation command to use a non-interactive frontend, improving reliability during package installation.
2025-10-31 08:36:59 +02:00
anonpenguin23
472b7c10bb feat: automate terms acceptance in Anon configuration and installation
- Added automatic acceptance of terms in the Anon configuration file to streamline the setup process.
- Updated the installation script to pre-accept terms, eliminating interactive prompts during installation.
- Enhanced output messages to reflect the auto-accepted terms for better user awareness.
2025-10-31 08:24:32 +02:00
anonpenguin23
fe16d503b5 feat: integrate Anyone Relay (Anon) into the development environment
- Added support for installing and configuring the Anyone Relay (Anon) for anonymous networking in the setup process.
- Updated the Makefile to include the Anon client in the development stack, allowing it to run alongside other services.
- Implemented a new HTTP proxy handler for the Anon service, enabling proxied requests through the Anyone network.
- Enhanced the installation script to manage Anon installation, configuration, and firewall settings.
- Introduced tests for the Anon proxy handler to ensure proper request validation and error handling.
- Updated documentation to reflect the new Anon service and its usage in the development environment.
2025-10-30 06:21:32 +02:00
3f3ef9d1ac Revert "feat: enhance setup process with firewall configuration"
This reverts commit 030ea88cf6dafd274f077cc87d3bdd5b968dc33e.
2025-10-27 10:29:00 +02:00
anonpenguin23
030ea88cf6
feat: enhance setup process with firewall configuration
- Added a new step to configure the UFW firewall during the setup process, ensuring necessary ports are opened for SSH, P2P, and Gateway API.
- Updated the setup command output to reflect the new firewall configuration step.
- Refactored the setup logic to maintain proper sequence and clarity in the setup steps.
- Modified the installation script to update the documentation link for better user guidance.
2025-10-26 12:55:32 +02:00
anonpenguin23
c315cd4a86
feat: enhance installation script for persistent Go setup
- Updated `setup.go` to add Go binary path to the current process and the `debros` user's `.bashrc` for persistent availability.
- Implemented error handling for updating `.bashrc` and ensured proper ownership of the file.
- Refined `install-debros-network.sh` to improve OS detection, dependency checks, and installation flow, including downloading the latest release of `network-cli` from GitHub.
- Streamlined the installation process with clearer logging and error messages, enhancing user experience.
2025-10-26 07:02:25 +02:00
anonpenguin23
43c0caaf7f
feat: overhaul GoReleaser configuration and CLI structure
- Updated `.goreleaser.yaml` to reflect the new project name and added multi-platform binary builds for `network-cli`, `node`, `gateway`, and `identity`.
- Enhanced the CLI by modularizing commands into separate packages for better maintainability and clarity.
- Introduced a comprehensive environment management system, allowing users to switch between local, devnet, and testnet environments seamlessly.
- Added interactive setup commands for VPS installation, improving user experience and installation flow.
- Updated the installation script to be APT-ready, providing clear instructions for users and ensuring a smooth setup process.
- Enhanced documentation and changelog to reflect the new features and improvements.
2025-10-26 06:30:44 +02:00
anonpenguin23
f0576846bc
ypdate 2025-10-25 16:46:08 +03:00
anonpenguin23
33a13db44d
fix: enforce interactive mode requirement in installation script
- Added a check to ensure the script is run in an interactive terminal, providing clear error messages and instructions if not.
- Removed non-interactive mode handling for user creation, streamlining the user experience and ensuring necessary prompts are displayed.
- Updated instructions for re-running the script after user creation to enhance clarity.
2025-10-25 16:12:36 +03:00
anonpenguin23
46d69baf63
fix: enhance user switching logic in installation script for non-interactive mode
- Added a check to skip re-execution of the script as the 'debros' user when running in non-interactive mode.
- Ensured that the installation can proceed as root without switching users in non-interactive scenarios, improving usability.
2025-10-25 16:04:58 +03:00
anonpenguin23
38e77c79c6
feat: enhance debros user creation in installation script for non-interactive mode
- Added support for non-interactive mode to automatically create the 'debros' user without user prompts.
- Implemented passwordless login for the 'debros' user in non-interactive mode.
- Retained interactive prompts for user creation when not in non-interactive mode, improving user experience and flexibility.
2025-10-25 16:01:44 +03:00
anonpenguin23
e5a71ba295
fix: improve user prompt in installation script for debros user creation
- Updated the user creation prompt to use `read -rp` for better user experience by allowing inline input without a newline.
- Ensured clarity in the prompt message for creating the 'debros' user.
2025-10-25 15:58:08 +03:00
anonpenguin23
6bce9f23d0
chore: remove domain configuration and ACME TLS support from gateway
- Removed the `Domain` field from the gateway configuration to simplify setup.
- Eliminated related logic for domain validation and ACME certificate management.
- Updated installation script to remove references to ACME certificate storage and HTTP/HTTPS port configurations.
- Bumped version in Makefile to 0.52.0-beta to reflect changes.
2025-10-25 15:52:47 +03:00
anonpenguin23
ecc5f3241a
feat: improve user setup and installation flow in debros network script
- Added functionality to check and create the 'debros' user if it does not exist, with options for password setup or passwordless login.
- Enhanced user switching logic to ensure the script runs as the 'debros' user or prompts for necessary actions.
- Updated the installation script to provide clearer instructions for user switching and installation continuation.
- Refined existing checks and improved error handling for a smoother installation experience.
2025-10-25 15:41:29 +03:00
anonpenguin23
a626982636
feat: enhance installation script to support user switching and directory setup
- Updated the installation directory to a specific path (`/home/debros`) for better organization.
- Added a function to check and switch to the 'debros' user if not already running as that user.
- Improved user creation logic to ensure the 'debros' user is set up correctly with the appropriate home directory.
- Enhanced directory setup to create necessary subdirectories and set permissions accordingly.
2025-10-25 14:49:55 +03:00
anonpenguin23
6ec4f7f903
refactor: update installation script to use user home directory
- Changed the installation directory from `/opt/debros` to the user's home directory for improved flexibility.
- Updated systemd service configurations to reflect the new installation path for both node and gateway services.
- Ensured that read/write paths are aligned with the new installation directory.
2025-10-25 14:40:45 +03:00
anonpenguin23
82d7dc2f2a
feat: enhance update mode in installation script to generate missing configuration files
- Added logic to check for the presence of essential configuration files during update mode.
- If missing, the script now generates the necessary `bootstrap.yaml` and `gateway.yaml` files to ensure proper setup.
2025-10-25 14:35:13 +03:00
anonpenguin23
8ba3c838e9
Updated script branch to nightly 2025-10-25 14:28:11 +03:00
anonpenguin23
d2b671b335
feat: add domain configuration and ACME TLS support for gateway
- Introduced a new `Domain` field in the gateway configuration to support HTTPS and ACME certificate provisioning.
- Implemented domain validation to ensure proper format.
- Enhanced the main gateway logic to handle ACME challenges and manage TLS certificates using CertMagic.
- Updated installation script to create necessary directories for ACME certificate storage and configure firewall rules for HTTP/HTTPS ports.
2025-10-25 13:45:53 +03:00
anonpenguin
5939cf413e
Merge branch 'main' into nightly 2025-10-25 13:05:00 +03:00
4bd91ae83e Fix: Use config file instead of data directory in systemd service 2025-10-25 12:19:31 +03:00
anonpenguin23
a9d624c0f6
refactor: enhance DeBros network installation script
- Updated script to support a complete DeBros network node installation with gateway.
- Improved user management by introducing a variable for the debros user.
- Added support for idempotent updates and secure systemd service management for both node and gateway services.
- Replaced the configuration wizard with automated configuration file generation using network-cli.
- Enhanced firewall configuration instructions and service management commands for better usability.
2025-10-25 08:40:06 +03:00
anonpenguin23
b6db781ce2
- Added identity/main.go to generate identity and peer id
- Added encryption module identity.go for reusable identity create, save etc funtions
- Updated make file to support identity/main.go
- Updated node/node.go on loadOrCreateIdentity to use encryption.identity
- Updated cli/main.go to remove fallbacks for identity
- Updated install-debros-network.sh script to use new ./cmd/identity and fixed port order on print
- Updated makefile and changelog
2025-09-26 07:53:20 +03:00
anonpenguin23
66f10df2e1 - Updated Gateway port from 8080/8005 to 6001 - Added Gateway port on
install-debros-network.sh
2025-09-20 08:15:31 +03:00
anonpenguin23
ff3b15108d replaced git.debros.io with github.com 2025-09-18 15:27:53 +03:00
a6129d3fc2 Rewrite docs for modern node/client architecture and install system 2025-08-14 15:19:23 +03:00
b744f7f513 refactor: standardize ports (LibP2P 4001, RQLite 5001/7001) and remove .env configuration 2025-08-08 20:09:28 +03:00
089916b5dd Fix port conflict between RQLite and LibP2P
CRITICAL FIX: Separate RQLite and LibP2P ports to prevent service startup failures

Changes:
- LibP2P now uses port 4000 (was conflicting with RQLite on 4001)
- RQLite continues to use port 4001 for HTTP API
- RQLite Raft uses port 4002
- Updated bootstrap peer configurations to use port 4000
- Updated install script port configurations
- Fixed firewall configuration to allow correct ports

This resolves the 'bind: address already in use' error that was preventing
the debros-node service from starting properly.
2025-08-06 08:44:23 +03:00
cc276ccc22 Fix install script service management to only use debros-node
- Remove references to debros-bootstrap service in update logic
- Standardize on single debros-node service for all node types
- Fix service stopping/starting during updates
- Clean up legacy service references
2025-08-06 08:39:44 +03:00
3975b5a59d Fix debros-node service failing due to invalid -port flag
- Remove invalid -port flag from systemd service ExecStart command
- The node binary doesn't support -port flag, it uses hardcoded port 4001
- Fix variable name RAFT_NODE_PORT to RAFT_PORT in two places
- Update check_existing_installation to only check for node binary since bootstrap binary was removed

This resolves the service startup failure where the service was exiting with:
'flag provided but not defined: -port'
2025-08-06 07:51:23 +03:00
b9ef151643 Merge branch 'main' of https://git.debros.io/DeBros/network 2025-08-05 22:28:34 +03:00
cd74a2df68 Refactor node and bootstrap configurations for improved clarity and consistency; unify RQLite and Raft ports across nodes, update environment setup, and enhance logging for node operations. 2025-08-05 22:28:12 +03:00
f470884b42 Fix spacing issues in install script that were causing command failures
- Fixed variable references with extra spaces that caused chmod commands to fail
- Corrected '' variable interpolation in permission commands
- Script now properly sets directory permissions without syntax errors
2025-08-04 19:03:11 +03:00
0a0756d4da Update RQLite raft port to 7001 in configuration files 2025-08-04 18:51:42 +03:00
cad45efb71 Refactor go.mod to remove indirect dependency on godotenv and update RQLite node configuration 2025-08-04 18:51:11 +03:00
bf32cc2a49 Add production environment support for bootstrap peers and RQLite connections 2025-08-04 18:31:49 +03:00
0cabfd6381 Clean up output messages: remove duplicate 'node' and Node Type line
- Remove duplicate 'node node' references in service start messages
- Remove 'Node Type: node' line from completion output
- Simplify service messages to 'Starting/Started DeBros Network service'
- Simplify final success messages to remove redundant 'node' references
- Clean, professional output without confusing terminology duplication
2025-08-04 17:01:29 +03:00
d447f6546b Force NODE_TYPE to 'node' in update mode to complete bootstrap migration
- Remove logic that detects existing bootstrap.yaml and sets NODE_TYPE to 'bootstrap'
- Always use NODE_TYPE='node' in update mode for consistent terminology
- This ensures all services, configs, and outputs use 'node' terminology
- Completes the full migration from bootstrap to node naming convention
- Existing bootstrap installations will be updated to use node terminology
2025-08-04 16:58:07 +03:00
4f204a37f4 Fix final bootstrap port references in completion output
- Replace BOOTSTRAP_PORT, RQLITE_BOOTSTRAP_PORT, RAFT_BOOTSTRAP_PORT
  with NODE_PORT, RQLITE_NODE_PORT, RAFT_NODE_PORT in completion output
- Ensures all port variables are correctly defined and displayed
- Completes the full bootstrap-to-node terminology migration
2025-08-04 16:55:20 +03:00
946e2568bb Fix ExecStart command in systemd service to use NODE_PORT instead of BOOTSTRAP_PORT
- Update service creation to use NODE_PORT instead of undefined BOOTSTRAP_PORT
- This fixes the service startup failure where the wrong port variable was referenced
- Service command now correctly uses: /opt/debros/bin/node -data /opt/debros/data/node -port 4001
2025-08-04 16:54:52 +03:00
8b1fbdd9e3 Rename all bootstrap references to node in installation script
- Replace BOOTSTRAP_PORT with NODE_PORT (4001)
- Replace RQLITE_BOOTSTRAP_PORT with RQLITE_NODE_PORT (5001)
- Replace RAFT_BOOTSTRAP_PORT with RAFT_NODE_PORT (7001)
- Update port checks to use new node port variables
- Update configuration generation to use NODE_PORT variables
- Update firewall configuration to use node ports
- Update systemd service creation to use node terminology
- Simplify port management by removing separate bootstrap/node distinctions
- All installations now use consistent 'node' terminology
2025-08-04 16:51:52 +03:00
73d4d2b17b Fix Text file busy error during binary updates
- Stop running services before copying new binaries during update mode
- Wait 3 seconds for services to fully stop
- Restart services after successful binary update
- Prevents 'Text file busy' error when overwriting executable files
- Only affects update mode, fresh installs work normally
2025-08-04 16:46:41 +03:00