Commit graph

180 commits

Author SHA1 Message Date
8a253fdf90
feat(invite): streamline invite handling and logging
Refactored the invite handling process within the invite callback for better consistency and maintainability. Swapped out a basic logging function with the bot's standardized logger for improved logging consistency across the application. Additionally, simplified the room joining process by removing redundant response handling, thus enhancing code readability and maintainability. These changes aim to unify the logging approach within the bot and ensure smoother invite processing without altering the underlying functionality.
2024-05-18 21:37:03 +02:00
28752ae3da
refactor: mark base imports in tools as used
Adjusted import statements in `tools.__init__.py` to silence linting warnings regarding unused imports. This emphasizes that `BaseTool`, `StopProcessing`, and `Handover` are intentionally imported for export purposes, despite not being directly referenced. This change aids in maintaining cleaner code and reduces confusion around import intentions.

No functional impact or changes in behavior are expected as a result of this refactor.
2024-05-18 21:36:21 +02:00
df567d005e
refactor(callbacks): remove test callbacks and imports
This commit streamlines the `callbacks` module by removing the debugging and testing related callbacks (`test_callback` and `test_response_callback`) along with their associated imports. It focuses on enhancing the clarity and maintainability of the callback handling by eliminating unused code paths and dependencies that were specifically used for testing purposes. This cleanup is part of an effort to mature the codebase and reduce potential confusion for new contributors by ensuring that only operational code is present in the production paths. This should not affect the existing functionality but will make future modifications and understanding of the callback mechanisms more straightforward.
2024-05-18 21:36:06 +02:00
e2e31060ce
refactor: improve code readability and efficiency
Enhanced code readability by formatting multiline log statements and adding missing line breaks in conditional blocks. Adopted a more robust error handling approach by catching general exceptions in encoding determination. Eliminated redundant variable assignments for async tasks to streamline event handling and response callbacks, directly invoking `asyncio.create_task()` for better clarity and efficiency. Simplify message and file sending routines by removing unnecessary status assignments, implying a focus on action over response verification. Lastly, optimized message truncation logic by discarding the unused result, focusing on in-place operation for token limit adherence. These changes collectively contribute to a cleaner, more maintainable, and efficient codebase, addressing potential bugs and performance bottlenecks.
2024-05-18 21:33:32 +02:00
7f8ff1502a
fix: remove redundant API usage log call
Removed an unnecessary call to `log_api_usage` after command execution in the calculate command handler. This change eliminates redundant logging that didn't contribute valuable insights and led to clutter in log files, streamlining the process and potentially improving performance by reducing I/O operations.
2024-05-18 21:32:32 +02:00
75d00ea50e
fix: correct user variable in invite error log
Updated the logger to use `event.sender` instead of an undefined `user` variable when logging a failed space invitation, ensuring the correct information is logged. This change addresses a bug where the wrong variable was referenced, potentially causing confusion when diagnosing issues with space invites.
2024-05-18 21:31:56 +02:00
2c04d8bf9c
refactor: remove unused json import from ai base
The ai base module in gptbot no longer requires the json package, leading to its removal. This cleanup enhances code readability and reduces unnecessary import overhead, streamlining the functionality of the ai base class without affecting its external behavior. Such optimizations contribute to the overall maintainability and performance of the codebase.
2024-05-18 21:31:17 +02:00
27df072c0d
fix: correct target room for avatar setup
Fixed an issue where the bot attempted to set the avatar for the wrong room when creating a new room. The avatar is now correctly assigned to the newly created room instead of the incorrectly referenced room variable. This ensures that newly created rooms properly display the intended logo from the start, improving the user experience by maintaining consistent branding across rooms.
2024-05-18 21:30:48 +02:00
141e89ab11
feat: add PyPI and Git badges to README
Enhanced project visibility and accessibility by including new badges in the README. These additions are aimed at providing quick links to the package on PyPI, showing the supported Python versions, license information, and the latest Git commit status. These enhancements make it easier for users and contributors to find important project details, contributing to a more open and engaging community.

This change underscores our commitment to transparency and support for the development community.
2024-05-17 16:36:19 +02:00
47bf7db380
refactor(ci): streamline Docker CI/CD workflows
Removed redundant Docker CI/CD workflow for the 'latest' tag and integrated its functionality into the existing tagging workflow. This change not only reduces the redundancy of having separate workflows for 'latest' and version-specific tags but also simplifies the CI/CD process by having a single, unified workflow for Docker image publications. Moving forward, every push will now ensure that the 'latest' tag is updated alongside the version-specific tags, maintaining a smoother and more predictable deployment and versioning flow.
2024-05-17 16:12:11 +02:00
9c6b6f5b99
feat(dependabot): enable daily pip updates
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m8s
Added a Dependabot configuration to automate dependency updates for the Python package ecosystem. Dependabot will now check for updates on a daily basis, ensuring that our project dependencies remain up-to-date with the latest security patches and features without manual oversight. This proactive approach towards dependency management will aid in minimizing potential security vulnerabilities and compatibility issues, fostering a more secure and stable development environment.
2024-05-17 16:08:33 +02:00
344e736006
docs: emphasize venv usage in installation guide
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m25s
Updated the README to strengthen the recommendation of using a virtual environment (venv) during installation. This adjustment aims to guide users towards best practices in Python environment management, potentially reducing common issues related to package dependencies and conflicts.
2024-05-17 12:46:03 +02:00
3e966334ba
refactor(pyproject.toml): streamline and update dependencies
This commit simplifies the pyproject.toml structure for better readability and maintenance. Key changes include formatting author and license information, consolidating dependency lists into a more concise format, and adding the `future` package to dependencies to ensure forward-compatibility. Optional dependencies are now listed in a more compact style, and the development dependencies section has been cleaned up. These adjustments make the project configuration cleaner and more accessible, facilitating future updates and dependency management.
2024-05-17 11:54:30 +02:00
9178ab23ac
fix: update Pantalaimon default port in README
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m3s
Corrected the default port for Pantalaimon from 8010 to 8009 in the README documentation. This change aligns the documentation with the latest Pantalaimon configuration standards, ensuring that users setting up their homeserver URL in the bot's config.ini file use the correct port. This update is crucial for new users during initial setup to avoid connectivity issues.
2024-05-17 11:49:21 +02:00
ee7e866748
feat(config): change default port to 8009
Some checks are pending
Docker CI/CD / Docker Build and Push to Docker Hub (push) Waiting to run
Updated the default listening port in pantalaimon.example.conf from 8010 to 8009. This alteration ensures compatibility with new network policies and avoids collision with commonly used ports in the default configuration. It's an important change for users setting up new instances, enabling smoother initial configurations without manual port adjustments.
2024-05-17 11:45:41 +02:00
1cd7043a36
feat: enable third-party model vision support
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m8s
Python Package CI/CD / Setup and Test (push) Successful in 1m8s
Python Package CI/CD / Publish to PyPI (push) Successful in 37s
Introduced the `ForceVision` configuration option to allow usage of third-party models for image recognition within the OpenAI setup. This change broadens the flexibility and applicability of the bot's image processing capabilities by not restricting to predefined vision models only. Also, added missing properties to the `OpenAI` class to provide comprehensive control over the bot's behavior, including options for forcing vision and tools usage, along with emulating tool capabilities in models not officially supporting them. These enhancements make the bot more adaptable to various models and user needs, especially for self-hosted setups.

Additionally, updated documentation and increment version to 0.3.12 to reflect these changes and improvements.
2024-05-17 11:37:10 +02:00
8e0cffe02a
feat: enhance AI integration & update models
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 7m53s
Python Package CI/CD / Setup and Test (push) Successful in 1m13s
Python Package CI/CD / Publish to PyPI (push) Successful in 37s
Refactored the handling of AI providers to support multiple AI services efficiently, introducing a `BaseAI` class from which all AI providers now inherit. This change modernizes our approach to AI integration, providing a more flexible and maintainable architecture for future expansions and enhancements.

- Adopted `gpt-4o` and `dall-e-3` as the default models for chat and image generation, respectively, aligning with the latest advancements in AI capabilities.
- Integrated `ruff` as a development dependency to enforce coding standards and improve code quality through consistent linting.
- Removed unused API keys and sections from `config.dist.ini` to streamline configuration management and clarify setup processes for new users.
- Updated the command line tool for improved usability and fixed previous issues preventing its effective operation.
- Enhanced OpenAI integration with advanced settings for temperature, top_p, frequency_penalty, and presence_penalty, enabling finer control over AI-generated outputs.

This comprehensive update not only enhances the bot's performance and usability but also lays the groundwork for incorporating additional AI providers, ensuring the project remains at the forefront of AI-driven chatbot technologies.

Resolves #13
2024-05-17 11:26:37 +02:00
02887b9336
feat: add main_sync wrapper for asyncio compatibility
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 10m11s
Refactored the main execution pathway to introduce a `main_sync` function that wraps the existing asynchronous `main` function, facilitating compatibility with environments that necessitate or prefer synchronous execution. This change enhances the bot's flexibility in various deployment scenarios without altering the core asynchronous functionality.

In addition, expanded the exception handling in `get_version` to catch all exceptions instead of limiting to `DistributionNotFound`. This broadens the robustness of version retrieval, ensuring the application can gracefully handle unexpected issues during version lookup.

Whitespace adjustments improve code readability by clearly separating function definitions.

These adjustments contribute to the maintainability and operability of the application, allowing for broader usage contexts and easier integration into diverse environments.
2024-05-17 10:58:01 +02:00
bc06f8939a
refactor: applying lots of linting
Some checks failed
Docker CI/CD / Docker Build and Push to Docker Hub (push) Has been cancelled
This commit removes unnecessary imports across several modules, enhancing code readability and potentially improving performance. Notably, `KeysUploadError` and `requests` were removed where no longer used, reflecting a cleaner dependency structure. Furthermore, logging calls have been standardized, removing dynamic string generation in favor of static messages. This change not only makes the logs more consistent but also slightly reduces the computational overhead associated with log generation. The removal of unused type hints also contributes to a more focused and maintainable code base.

Additionally, the commit includes minor text adjustments for user messages, replacing dynamic content with fixed strings where the dynamism was not needed. This enhances both the clarity and security of user-directed messages by avoiding unnecessary string formatting operations.

Finally, the simplification of the migration script and the adjustment in the tools module underscore an ongoing effort to maintain clean and efficient code infrastructure.
2024-05-17 10:54:54 +02:00
5bbcd3cfda
feat: add debug and keyring config options
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m6s
Added `LogLevel` and `UseKeyring` configuration options to the example configuration file to provide users with more control over logging verbosity and the decision to utilize a system keyring for credentials storage. The LogLevel option allows for easier debugging by adjusting the verbosity of logs, whereas the UseKeyring option offers flexibility in credential management, catering to environments where a system keyring may not be preferred or available.

These changes enhance the tool's usability and adaptability to various user environments and debugging needs.
2024-05-17 10:38:23 +02:00
15a93d8231
feat: Expand bot usage control and API support
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 17m54s
Python Package CI/CD / Setup and Test (push) Successful in 1m54s
Python Package CI/CD / Publish to PyPI (push) Successful in 55s
Enhanced bot flexibility by enabling the specification of room IDs in the allowed users' list, broadening access control capabilities. This change allows for more granular control over who can interact with the bot, particularly useful in scenarios where the bot's usage needs to be restricted to specific rooms. Additionally, updated documentation and configurations reflect the inclusion of new AI models and self-hosted API support, catering to a wider range of use cases and setups. The README.md and config.dist.ini files have been updated to offer clearer guidance on setup, configuration, and troubleshooting, aiming to improve user experience and ease of deployment.

- Introduced the ability for room-specific bot access, enhancing user and room management flexibility.
- Expanded AI model support, including `gpt-4o` and `ollama`, increases the bot's versatility and application scenarios.
- Updated Python version compatibility to 3.12 to ensure users are leveraging the latest language features and improvements.
- Improved troubleshooting documentation to assist users in resolving common issues more efficiently.
2024-05-16 07:24:34 +02:00
e58bea20ca
feat(logging): Add debug log for empty OpenAI responses
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 16m29s
Introduces logging for cases where OpenAI's API returns an empty response, ensuring that such occurrences are captured for debugging purposes. This change enhances visibility into the interaction with OpenAI's endpoint, facilitating easier identification and resolution of issues where empty responses are received, potentially indicating API limitations, network issues, or unexpected behavior from the AI model.
2024-05-16 06:40:03 +02:00
bd0099aa29
feat(docker): Extended information on setting up Pantalaimon with Docker
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 7m58s
2024-05-15 14:33:35 +02:00
e46be65707
feat: Add optional location name to weather report
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 9m33s
This update allows users to provide a location name for their weather reports, which can be useful when requesting weather information for specific locations.
2024-05-10 18:31:24 +02:00
9a4c250eb4
fix: Enhance error handling for user authentication
When processing large volumes of data, it's essential to handle errors gracefully and provide clear feedback to users. This change introduces additional checks to ensure robust error handling during user authentication, reducing the likelihood of errors propagating further down the pipeline.

This improvement not only enhances the overall stability of the system but also provides a better user experience by providing more informative error messages in the event of an issue.
2024-05-10 18:18:40 +02:00
f6a3f4ce66
feat: Update pantalaimon-related scripts and configuration**
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m44s
Renamed `pantalaimon_first_login.py` to `fetch_access_token.py` to better reflect its purpose. Additionally, updated README to remove obsolete instructions for using pantalaimon with the bot.
2024-05-10 17:27:30 +02:00
b88afda558
refactor: Update dependency matrix-nio to 0.24.0
Some checks failed
Docker CI/CD / Docker Build and Push to Docker Hub (push) Failing after 7m54s
This commit updates the `matrix-nio` dependency to version 0.24.0, ensuring compatibility and new features.
2024-05-10 17:07:30 +02:00
df3697b4ff
feat: Add Docker support and TrackingMore dependency
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m42s
Release version 0.3.9 introduces Docker support, enhancing deployment options by allowing the bot to run in a containerized environment. This update greatly simplifies deployment and scaling processes. Additionally, the inclusion of the TrackingMore dependency expands the bot's functionality, enabling advanced tracking features. These changes collectively aim to improve the bot's adaptability and efficiency in handling tasks.
2024-04-23 18:13:53 +02:00
17c6938a9d
feat: Switch Docker CI/CD to main branch & release v0.3.9
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m34s
Python Package CI/CD / Setup and Test (push) Successful in 1m27s
Python Package CI/CD / Publish to PyPI (push) Successful in 38s
- Updated the Docker CI/CD workflow to trigger on pushes to the main branch, aligning with standard Git flow practices for production deployment.
- Advanced project version to 0.3.9, marking a new release with consolidated features and bug fixes.

This adjustment ensures that the Docker images are built and deployed in a more streamlined manner, reflecting our shift towards a unified branching strategy for releases. The version bump signifies the stabilization of new functionalities and enhancements for broader usage.
2024-04-23 18:12:39 +02:00
e8691194a9
CHANGELOG update
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m56s
2024-04-23 18:06:55 +02:00
c7c2cbc95f
feat: support password-based Matrix login
Some checks failed
Docker CI/CD / Docker Build and Push to Docker Hub (push) Has been cancelled
This update introduces the ability for the bot to use a Matrix UserID and password for authentication, in addition to the existing Access Token method. Upon the first run with UserID and password, the bot automatically converts these credentials into an Access Token, updates the configuration with this token, and removes the password for security purposes. This enhancement simplifies the initial setup process for new users by directly utilizing Matrix login credentials, aligning with common user authentication workflows and enhancing security by not storing passwords long-term.

Refactored the bot initialization process in `GPTBot.from_config` to support dynamic login method selection based on provided credentials, and implemented automatic configuration updating to reflect the newly obtained Access Token and cleaned credentials.

Minor adjustments include formatting and comment clarification for better readability and maintenance.

This change addresses the need for a more straightforward and secure authentication process for bot deployment and user experience improvement.
2024-04-23 18:05:50 +02:00
91a028d50b
refactor: streamline Docker setup in README
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 9m12s
Removed detailed Docker setup instructions, opting to simplify the Docker usage section by retaining only the Docker Compose method. This change aims to declutter the README and encourage a more standardized setup process for users, reducing potential confusion and maintaining focus on the primary installation method via Docker Compose. The update includes a minor adjustment to the database initialization step, ensuring users are guided to prepare their environment fully before running the bot. This revision makes the setup process more approachable and efficient, especially for newcomers.

By directing users to the `Running` section for config file setup instructions, we maintain consistency and avoid duplicative content, keeping the README streamlined and more manageable.
2024-04-23 17:47:26 +02:00
5a9332d635
feat: Replace deprecated dependency
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 8m56s
Transitioned from the deprecated `pkg_resources` to `importlib.metadata` for package version retrieval, improving performance and future compatibility.
2024-04-23 17:30:21 +02:00
7745593b91
feat(docker-compose): mount local database for persistence
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 9m16s
Added a volume to the `matrix-gptbot` service configuration in `docker-compose.yml`, mounting the local `database.db` file into the container. This change enables persistent storage for the bot's data, ensuring that data is not lost when the container is restarted or redeployed. It enhances data management and allows for more robust operation of the bot service by leveraging persistency.

This development is crucial for scenarios requiring data retention across bot updates and system maintenance activities.
2024-04-23 17:08:13 +02:00
ca68ecb282
feat: add trackingmore API and ffmpeg
- Included the `ffmpeg` package in the Docker environment to support multimedia content processing.
- Added `trackingmore-api-tool` as a dependency to expand the bot's functionality with tracking capabilities.
- Adjusted the `all` dependencies list in `pyproject.toml` to include the `trackingmore` module, indicating a broader feature set for the application.
- Updated the bot class to prepare for integrating `TrackingMore` alongside existing services like `OpenAI` and `WolframAlpha`, highlighting an intention to make such integrations configurable in the future.

This enhancement enables the bot to interact with multimedia content more effectively and introduces package tracking features, laying groundwork for configurable service integrations.
2024-04-23 17:07:57 +02:00
076eb2d243
feat: switch to pre-built Docker image & update ports
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 6m19s
Moved from building the GPT bot Docker container on the fly to using a pre-built image, enhancing the setup's efficiency and reducing build times for deployments. Adjusted the server's exposed port to resolve conflicts and standardize deployment configurations. Additionally, locked in the `future` package version to ensure compatibility with legacy Python code, mitigating potential future incompatibility issues.
2024-04-23 16:45:16 +02:00
eb9312099a
feat(workflows): streamline Docker CI/CD processes
All checks were successful
Docker CI/CD / Docker Build and Push to Docker Hub (push) Successful in 5m34s
Removed redundant internal Docker CI/CD workflow and unified naming for external Docker workflows to improve clarity and maintainability. Introduced a new workflow for tagging pushes, aligning deployments closer with best practices for version management and distribution. This change simplifies the CI/CD pipeline, reducing duplication and potential confusion, while ensuring that Docker images are built and pushed efficiently for both internal developments and tagged releases.

- Docker CI/CD internals were removed, focusing efforts on standardized workflows.
- Docker CI/CD workflow names were harmonized to reinforce their universal role across projects.
- A new tagging workflow supports better version control and facilitates automatic releases to Docker Hub, promoting consistency and reliability in image distribution.

This adjustment lays the groundwork for more streamlined and robust CI/CD operations, providing a solid framework for future enhancements and scalability.
2024-04-23 11:46:33 +02:00
fc26f4b591
feat(workflows): add Docker CI/CD for Forgejo, refine Docker Hub flow
Some checks failed
Docker CI/CD Internal / Docker Build and Push to Forgejo Docker Registry (push) Failing after 5m31s
Docker CI/CD External / Docker Build and Push to Docker Hub (push) Successful in 5m32s
Introduced a new CI/CD workflow specifically for building and pushing Docker images to the Forgejo Docker Registry, triggered by pushes to the 'docker' branch. This addition aims to streamline Docker image management and deployment within Forgejo's infrastructure, ensuring a more isolated and secure handling of images. Concurrently, the existing workflow for Docker Hub has been refined to clarify its purpose: it is now explicitly focused on pushing to Docker Hub, removing the overlap with Forgejo Docker Registry operations. This delineation enhances the clarity of our CI/CD processes and ensures a cleaner separation of concerns between public and internal image repositories.
2024-04-23 11:10:50 +02:00
5bc6344fdf
fix(docker): streamline tag format for latest image
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 5m59s
Removed a duplicate and unnecessary line specifying the `latest` tag for the docker image in the workflow. This change simplifies the tag specification process, avoiding redundancy, and ensuring clear declaration of both the `latest` and SHA-specific tags for our docker images in CI/CD pipelines.
2024-04-23 10:52:09 +02:00
c94c016cf1
fix(docker): use env vars for GitHub credentials in workflows
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 5m37s
Migrated from direct GitHub context references to environment variables for GitHub SHA, actor, and token within the Docker build and push actions. This enhances portability and consistency across different execution environments, ensuring better compatibility and security when interfacing with GitHub and Forgejo Docker registries.
2024-04-23 10:45:57 +02:00
f049285cb1
feat(docker): support dynamic tag based on commit SHA
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 1m34s
Enhanced Docker build workflows in `.forgejo/workflows/docker-latest.yml` to include dynamic tagging based on the GITHUB_SHA, alongside the existing 'latest' tag for both the kumitterer/matrix-gptbot and git.private.coffee/privatecoffee/matrix-gptbot images. This change allows for more precise versioning and traceability of images, facilitating rollback and specific version deployment. Also standardized authentication token variables for Docker login to the Forgejo Docker Registry, improving readability and consistency in CI/CD configurations.
2024-04-23 10:40:06 +02:00
35254a0b49
feat(docker): extend CI to push images to Forgejo
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 5m44s
Enhanced the CI pipeline for Docker images by supporting an additional push to the Forgejo Docker Registry alongside the existing push to Docker Hub. This change allows for better integration with private infrastructures and provides an alternative for users and systems that prefer or require images to be stored in a more controlled or private registry. It involves logging into both Docker Hub and Forgejo with respective credentials and pushing the built images to both, ensuring broader availability and redundancy of our Docker images.
2024-04-23 10:27:15 +02:00
bd0d6c5588
feat(docker): streamline Docker setup for GPTBot
All checks were successful
Docker CI/CD / Docker Build and Push (push) Successful in 7m23s
Moved the installation of build-essential and libpython3-dev from the Docker workflow to the Dockerfile itself. This change optimizes the Docker setup process, ensuring that all necessary dependencies are encapsulated within the Docker build context. It simplifies the CI workflow by removing redundant steps and centralizes dependency management, making the build process more straightforward and maintainable.

This adjustment aids in achieving a cleaner division between CI setup and application-specific build requirements, potentially improving build times and reducing complexity for future updates or dependency changes.
2024-04-23 09:52:43 +02:00
224535373e
feat(docker-workflow): add essential build dependencies
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 5m24s
Updated the docker-latest workflow to install additional critical build dependencies including build-essential and libpython3-dev, alongside docker.io. This enhancement is geared towards supporting a wider range of development scenarios and facilitating more complex build requirements directly within the CI pipeline.
2024-04-23 09:43:14 +02:00
a3b4cf217c
feat(docker-ci): enhance Docker CI/CD workflow
Some checks failed
Docker CI/CD / Docker Build and Push (push) Failing after 9m10s
Updated the Docker CI/CD pipeline in the `.forgejo/workflows/docker-latest.yml` to support better integration and efficiency. Key enhancements include setting a container environment with Node 20 on Debian Bookworm for consistency across builds, and installing Docker directly within the runner to streamline the process. This refinement simplifies the setup steps, reduces potential for errors, and possibly decreases pipeline execution time. These changes ensure that our Docker images are built and pushed in a more reliable and faster environment.
2024-04-23 09:26:15 +02:00
d23cfa35fa
refactor(docker-latest.yml): remove ubuntu-latest runner
Some checks failed
Docker CI/CD / docker (push) Failing after 1m35s
Removed the specific runner designation from the Docker workflow to allow for dynamic runner selection. This change aims to increase flexibility and compatibility across different CI environments. It reduces the dependency on a single OS version, potentially leading to better resource availability and efficiency in workflow execution.
2024-04-23 09:22:36 +02:00
054f29ea39
feat: Add Docker CI/CD and update docs for Docker usage
Some checks are pending
Docker CI/CD / docker (push) Waiting to run
Introduced a new Docker CI/CD workflow to automatically build and push images to Docker Hub on pushes to the 'docker' branch. This automation ensures that the latest version of the bot is readily available for deployment, facilitating easier distribution and deployment for users.

The README.md has been updated to improve clarity around installation methods, emphasizing PyPI as the recommended installation method while expanding on Docker usage. It now includes detailed instructions for Docker Hub images, local image building, and Docker Compose deployment, catering to a broader range of users and deployment scenarios. This update aims to make the bot more accessible and manageable by providing clear, step-by-step guidance for different deployment strategies.

Related to these changes, the documentation has been restructured to better organize information related to configuration and running the bot, ensuring users have a smoother experience setting up and deploying it in their environment.

These changes reflect our commitment to enhancing user experience and streamlining deployment processes, making it easier for users to adopt and maintain the matrix-gptbot in various environments.
2024-04-23 09:21:05 +02:00
f8861a16ad
feat: update GPTbot volume mapping
Changed the volume mapping for GPTbot service in `docker-compose.yml` from `settings.ini` to `config.ini`. This modification aligns the container configuration with the new application configuration file naming convention, facilitating easier configuration management and clarity for development and deployment processes.

This change is essential for maintaining consistency across our documentation and deployment scripts, ensuring that all references to configuration files are accurate and up to date.
2024-04-23 08:46:31 +02:00
ca07adbc93
refactor(docker): restructure project for improved management
Redesigned the Docker setup to enhance project structure and configuration management. Changes include a more organized directory structure within the Docker container, separating source code, project metadata, and licenses explicitly to the `/app` directory for better clarity and management. Additionally, integrated `pantalaimon` as a dependency service in `docker-compose.yml`, enabling secure communication with Matrix services by automatically managing settings and configurations through mounted files. This setup simplifies the development environment setup and streamlines deployments.
2024-04-23 08:42:12 +02:00
df2587ee74
feat: Add Docker support for GPTBot
Introduced Dockerfile and docker-compose.yml to encapsulate GPTBot into a Docker container. This simplifies deployment and ensures consistent environments across development and production setups. The Dockerfile outlines the necessary steps to build the image, incl. setting up the working directory, copying the current directory into the container, installing all dependencies, and defining the command to run the bot. The docker-compose.yml file further streamlines the deployment process by specifying service configuration, leveraging Docker Compose version 3.8 for its extended feature set and compatibility.

By containerizing GPTBot, we enhance portability, reduce set-up times for new contributors, and minimize "works on my machine" issues, fostering a more robust development lifecycle.
2024-04-23 08:25:12 +02:00