Commit Graph

179 Commits

Author SHA1 Message Date
dac062eee9 fix(generic): remove erroneous log message 2025-01-15 13:02:03 +02:00
1da8a2d319 feat(tfgrid3deployer): add delete method for deployments
- add a delete method for deployments which deletes all deployment
  contracts
- improve logging messages
- update examples according to changes
2025-01-15 13:00:04 +02:00
dc47c81b0c chore: remove old deployer code 2025-01-15 12:59:02 +02:00
babb114bcb refactor: regenerate tfgrid3deployer client code 2025-01-15 12:57:49 +02:00
b87185adb3 ... 2025-01-15 00:09:04 +01:00
b473c787e0 ... 2025-01-15 00:07:38 +01:00
f55654b3d4 ... 2025-01-14 23:59:29 +01:00
c2fa4f68d1 Merge branch 'development' of https://github.com/freeflowuniverse/herolib into development 2025-01-14 23:12:56 +01:00
d9e2d5ca8c docker 2025-01-14 23:12:54 +01:00
fa0dac57ec Merge pull request #24 from freeflowuniverse/development_grid
fix: use redis client reference in threefold grid module
2025-01-14 18:44:45 +02:00
55fc87d9f2 fix: use redis client reference in threefold grid module 2025-01-14 18:33:22 +02:00
c1e17d762d Merge pull request #22 from freeflowuniverse/development_hero_mdbook
fix: fix hero mdbook command
2025-01-14 15:42:13 +02:00
de102f33d9 fix: fix hero mdbook command 2025-01-14 15:34:02 +02:00
6a3e3a1177 Merge pull request #21 from freeflowuniverse/development_hero_git
refactor: remove unused url flag
2025-01-14 14:11:42 +02:00
e255d6ed65 refactor: remove unused url flag
- Removed the unused `url` flag from the hero CLI.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-14 14:06:51 +02:00
d9e4f49852 Merge pull request #20 from freeflowuniverse/development_ci_add_sudo
fix: add sudo to commands run in ci
2025-01-14 13:50:21 +02:00
0e449d7064 fix: update ci build workflow 2025-01-14 13:41:26 +02:00
5f13693160 ssh init 2025-01-14 12:22:17 +01:00
2a673553f1 fix hero for git 2025-01-14 11:53:28 +01:00
0674fa56b9 rename 2025-01-14 10:59:19 +01:00
3b71b7f1ca Merge branch 'development' of https://github.com/freeflowuniverse/herolib into development 2025-01-14 10:55:06 +01:00
8128f4c2f7 dockers are working with vscode 2025-01-14 10:55:02 +01:00
bb25b7663d Merge pull request #19 from freeflowuniverse/development_hero_generate
fix: correct generator command and templates
2025-01-14 11:47:36 +02:00
0b780b6901 fix: correct generator command and templates
- Correct the `generator` command to use a string flag for the path.
- Update templates to use correct heap allocation annotation.
- Remove unnecessary code in templates.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-14 11:41:50 +02:00
23c1456e7e docker creators 2025-01-14 10:25:35 +01:00
e1c93e8f98 Merge branch 'development' of https://github.com/freeflowuniverse/herolib into development 2025-01-14 06:26:13 +01:00
9c5fc9e65c git ignore 2025-01-14 06:26:09 +01:00
dac3b61116 Merge pull request #18 from freeflowuniverse/development_actions
Development actions
2025-01-13 18:59:22 +02:00
b101aee0ed chore: remove unused libs and add openai client
- Remove incorrect test paths.
- Ignore OpenAI client tests.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-13 18:52:29 +02:00
81f377a532 test: improve logger test and search functionality
- Improve the logger test to include more specific assertions.
- Add timestamp filtering to the logger search function.
- Fix a bug in the logger search function that prevented it from correctly handling continuation lines.
- Update redisclient tests to use the correct return type.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-13 18:46:13 +02:00
91f8520229 refactor: improve redis client and publisher
- Refactor the redis client to use a mutex for thread safety.
- Improve error handling in context and playbook factory.
- Remove the play_mdbook command and associated tests.
- Add play_publisher command and tests for publishing books.
- Update the repository cache to use a reference to the redis client.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-13 16:52:21 +02:00
da2881f973 refactor: improve rclone client factory
- Refactor the rclone client factory to improve its
  organization and functionality.
- Add support for multiple rclone instances with named
  instances.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-12 18:31:16 +02:00
67fc3b4a99 feat: improve OpenAI client
- Updated the OpenAI client to use environment variables for API keys.
- Improved the configuration and management of OpenAI clients.
- Added retry mechanism to HTTP requests for improved reliability.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-12 16:33:48 +02:00
4619a0759f Merge pull request #16 from freeflowuniverse/development_actions
Development actions
2025-01-12 14:22:58 +02:00
9e52132e4c ... 2025-01-12 13:18:56 +01:00
9083fccb58 test: improve robustness of incremental counter tests
- Replace `lut.incremental!` with a safer check using `if v := lut.incremental`.
- This ensures that the test doesn't panic if `incremental` is unexpectedly nil.
- The new assertions explicitly check for the existence of a value and its correctness.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-12 14:15:18 +02:00
5753e0eb58 refactor: improve collection export
- Remove unnecessary parameter from `errors_report` function.
- Pass `Collection` by mutable reference to `export` function.
- Fix `.collection` file content in export test.
- Update test cases to reflect changes.
- Correct path in test data.
- Use mutable reference for `col` in `Tree.export`.

Co-authored-by: mahmmoud.hassanein <mahmmoud.hassanein@gmail.com>
2025-01-12 14:06:21 +02:00
Mahmoud Emad
58a1f04a44 test: fix: handle potential null error in ping
- Updated assertions in `ipaddress_test.v` to handle potential null errors returned by the `ping` method.
2025-01-09 13:39:20 +02:00
Mahmoud Emad
3b580dcc1d fix: improve gitea and postgresql installation
- Improve the installation process for Gitea and PostgreSQL.
- Change the location of the Gitea config file to `/etc`.
- Add a health check for the PostgreSQL container.
- Ensure the Gitea user is created only if it doesn't exist.
- Add a restart command for Gitea to ensure it starts after.
- Improve error handling during user creation.
- Simplify PostgreSQL configuration in Gitea actions.
2025-01-09 13:31:57 +02:00
Mahmoud Emad
1fbb5bed4a chore: remove unnecessary debug print
- Remove a debug print statement that was no longer needed.
2025-01-09 10:49:51 +02:00
a63bba4558 fixes in gitea
Co-authored-by: omda <mahmmoud.hassanein@gmail.com>
2025-01-08 21:22:49 +02:00
Mahmoud Emad
de7c3ad36c fix: improve gitea installation
- Replace `osal.cmd_add` with explicit `cp` and `chmod`
- commands for more robust installation.
- This ensures gitea is correctly added to the path and
- made executable, providing better error handling.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-08 14:22:34 +02:00
Mahmoud Emad
d7efbeb53f fix: correct typo in Gitea SMTP port configuration
- Corrected a typo in the Gitea SMTP port configuration
- across multiple files: `gitea.vsh`, `gitea_model.v`,
- `server.v`, and `app.ini`.  The incorrect `smpt_port`
- was changed to the correct `smtp_port`.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-08 14:04:29 +02:00
Mahmoud Emad
7086a76a69 refactor: Simplify Gitea installer
- Remove unnecessary and incomplete code in `gitea_actions.v`.
- Simplify the `upload`, `startupcmd`, and `running` functions.
- Use a temporary file for the Gitea configuration.
- Implement a simpler health check using `curl`.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-08 13:41:24 +02:00
Mahmoud Emad
d6cb55abb1 feat: enable Gitea auto-start
- The Gitea installer now automatically starts the Gitea server after installation.
- Updated the installer to include a `start()` function.
- Added PostgreSQL installation and configuration to the Gitea installer.
- Improved error handling and logging.
- Updated configuration file template for better clarity and consistency.
- Renamed some variables for better readability.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-08 12:26:03 +02:00
Mahmoud Emad
e2a2f22571 refactor: improve gitea installer
- Refactor the Gitea installer to use a more robust and.
- configurable approach.  The installer now uses a more.
- flexible configuration system and handles different.
- platforms more effectively.  The installation process.
- is now more modular and easier to maintain.  The.
- previous method was overly simplistic and lacked.
- essential configuration options.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-08 11:43:01 +02:00
Mahmoud Emad
d631cc5af7 refactor: Migrate Gitea to Podman
- Migrate Gitea installation to use Podman containers.
- This simplifies the installation process and improves
- portability.  Removes reliance on direct binary
- downloads and manual installation steps.  The
- Gitea instance is now managed as a container.
- Updates configuration to reflect container-based
- deployment.  Updates version to 'latest' to
- leverage Podman's image management capabilities.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-06 17:12:59 +02:00
Mahmoud Emad
288bfd54d8 refactor: improve zinit process handling
- Improved error handling in `get` method of Zinit struct.
- Changed the return type of `new()` function in `zinit_factory.v` to `!&Zinit`.
- Updated `zinit_global_manager` to hold references to `Zinit` instances.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-06 16:40:52 +02:00
Mahmoud Emad
a19867c00b fix: Improve Postgresql healthcheck
- Remove unnecessary error return in `installed_()`.
- Remove `workdir` from `startupcmd()` as it's not needed.
- Simplify healthcheck to only return boolean.

Co-authored-by: mariobassem12 <mariobassem12@gmail.com>
2025-01-06 15:43:33 +02:00
Mahmoud Emad
51fb692f15 fix: Use container name instead of the server name 2025-01-06 15:29:20 +02:00