1
0
Fork 0
Commit graph

47 commits

Author SHA1 Message Date
Joao Gilberto Magalhaes
e4b62a3925 Add protocol support and improve FastCGI plugin handling
- Introduced `easyhaproxy.proto` annotation for backend protocol configuration.
- Automatically set FastCGI protocol (`proto: fcgi`) when using the FastCGI plugin.
- Updated Kubernetes processor to handle `proto` annotations.
- Enhanced EasyMapping to allow plugin overrides for host-level configs.
- Updated documentation to reflect new `proto` behavior and FastCGI improvements.
- Improved multiprocessing configuration with better context handling in `haproxy.py`.
2026-06-24 21:21:27 -04:00
Joao Gilberto Magalhaes
3fd0fe0d46 Update plugin paths from /etc/haproxy to /etc/easyhaproxy across tests, configs, and documentation 2026-02-18 16:35:57 -05:00
Joao Gilberto Magalhaes
d894778ddc Add Certbot and HAProxy management modules, container environment parsing, and plugin management framework
- Introduced `certbot.py` for ACME certificate management, including certificate issuance, renewal, and environment validation.
- Added `haproxy.py` for HAProxy process management, configuration validation, and dynamic command handling.
- Implemented `container_env.py` for reading and parsing environment variables with YAML overrides.
- Created `consts.py` for centralized management of static and dynamic paths.
- Added `manager.py` to enable plugin discovery, initialization, configuration, and execution.
- Refactored logging and configuration handling across modules for consistency.

Enhances modularity and scalability by introducing feature-dedicated modules and structured configuration handling.
2026-02-18 12:43:45 -05:00
Joao Gilberto Magalhaes
97845b8a52 Refactor E2E tests and configuration format
- Replaced `easymapping` configuration with `containers` for better maintainability and clarity.
- Introduced `DockerComposeFixture` class in `utils.py` to manage Docker Compose lifecycle and smart build strategy.
- Enhanced YAML-to-environment variable conversion in `ContainerEnv` for dynamic configuration support.
- Updated HAProxy configurations and test fixtures to reflect the new format.
- Improved test coverage for YAML parsing, environment variable handling, and HAProxy config generation.
2026-02-13 12:01:47 -05:00
Joao Gilberto Magalhaes
90b01b1f13 Add Kubernetes integration tests for EasyHAProxy examples
- Introduced a suite of pytest-based integration tests for Kubernetes using `kind`.
- Automated local installation of dependencies (`kind`, `kubectl`, and `helm`) when missing.
- Implemented fixtures for Kubernetes resource management and TLS secrets.
- Added end-to-end tests for HTTP and HTTPS ingress functionality.
2026-02-12 01:42:43 -05:00
Joao Gilberto Magalhaes
dc28b18351 Fix lint errors 2026-01-22 22:05:49 -05:00
Joao Gilberto Magalhaes
62e5c054f4 Refactor: modernize codebase by replacing deprecated patterns, simplifying imports, and applying type hinting refinements. 2026-01-22 21:47:33 -05:00
Joao Gilberto Magalhaes
542fab1607 Add ingress status update functionality to support various deployment modes
- Introduced `ingressStatus` configuration in Helm values to enable status updates and customize deployment modes (auto, daemonset, nodeport, clusterip).
- Implemented logic in the processor to detect deployment mode, retrieve ingress addresses, and update ingress status dynamically.
- Updated Kubernetes manifests to grant required permissions for `ingresses/status` operations and pass necessary environment variables for configuration.
- Adjusted Helm templates and associated Kubernetes examples to reflect the new ingress status update capability.
2025-12-15 21:11:02 -05:00
Joao Gilberto Magalhaes
c8f8320cfe Add IngressClass resource and update references to spec.ingressClassName across templates, examples, and documentation for consistency and backward compatibility
- Introduced new IngressClass resource in Helm templates to define `easyhaproxy` as the default ingress class.
- Updated Kubernetes examples to replace `easyhaproxy-ingress` with `easyhaproxy` as the ingress class name.
- Enhanced processor logic to support both the new `spec.ingressClassName` field and the deprecated `kubernetes.io/ingress.class` annotation.
- Revised documentation to reflect the changes and ensure alignment with Kubernetes recommendations.
2025-12-15 20:33:51 -05:00
Joao Gilberto Magalhaes
e8aceda402 Replace deprecated kubernetes.io/ingress.class annotation with spec.ingressClassName in Kubernetes examples and processor logic for compatibility with Kubernetes v1.22+. Updated documentation and examples to reflect the change while maintaining backward compatibility. 2025-12-15 19:58:08 -05:00
Joao Gilberto Magalhaes
75d6833769 Enhance plugin documentation and add Kubernetes plugin annotation support
- Updated `plugins.md` and `kubernetes.md` with detailed plugin configuration examples for Kubernetes annotations.
- Introduced support for `easyhaproxy.plugins` and `easyhaproxy.plugin.{name}.{key}` annotations in Kubernetes.
- Added comprehensive examples for JWT validation, IP whitelisting, and deny pages
2025-11-27 18:54:07 -05:00
Joao Gilberto Magalhaes
90e3df2b75 Add built-in plugin framework and initial plugins
- Introduced a plugin system enabling EasyHAProxy extensions.
- Added `CleanupPlugin` (GLOBAL): Handles temporary file cleanup.
- Added `CloudflarePlugin` (DOMAIN): Restores visitor IP from Cloudflare headers.
- Added `DenyPagesPlugin` (DOMAIN): Blocks access to specified paths.
- Documented the plugin architecture, configuration options, and built-in plugins in `docs/plugin-development.md` and `docs/plugins.md`.
2025-11-27 17:43:59 -05:00
Joao Gilberto Magalhaes
9d97d568ec creating constants 2024-11-18 09:13:11 -06:00
Joao Gilberto Magalhaes
06ea2bbd3f Log Refactor 2024-11-15 22:39:05 -06:00
Joao Gilberto Magalhaes
166b75cd75 Minor Fix Pre-Merge 2023-07-03 15:02:32 -05:00
Joao M
812590d86c
Merge branch 'issue/41' into issue/43 2023-07-03 14:19:00 -05:00
Joao M
78ea9b6810
Merge pull request #45 from byjg/issue/38
Issue #38 Add HTTPS Support for SSL
2023-07-03 13:37:38 -05:00
Joao Gilberto Magalhaes
3b2e9a43fd Fixing errors / reformating code 2023-07-01 18:26:50 -05:00
Joao Gilberto Magalhaes
078cb31eb7 Add parameter eab_kid and eab_hmac_key 2023-07-01 17:26:46 -05:00
Joao Gilberto Magalhaes
5dbe0a6d28 Renaming Letsencrypt to Certbot, since it will be more generic allowing other issuers. 2023-07-01 16:05:53 -05:00
Joao M
c41cc42d47
Merge branch '4.4.0' into issue/38 2023-06-27 00:20:55 -05:00
Joao Gilberto Magalhaes
2ddf276919 Defining Log Level 2023-06-27 00:19:18 -05:00
Joao M
38c2440145
Merge branch '4.4.0' into 4.3.1 2023-06-26 22:34:09 -05:00
Joao Gilberto Magalhaes
c0eb766339 Fix Swarm networking 2023-02-27 23:28:09 -06:00
Joao Gilberto Magalhaes
7dc683b254 Try to fix Docker Swarm with network attachment 2023-02-26 21:39:07 -06:00
Joao Gilberto Magalhaes
3cc9547388 Try Fix Swarm connection 2023-02-26 20:58:43 -06:00
Joao Gilberto Magalhaes
6e367174d4 Add ssl-check 2023-02-26 20:56:32 -06:00
Joao Gilberto Magalhaes
f791897449 Fix errors in the test 2023-02-08 19:27:50 -06:00
Joao Gilberto
f7969c2deb Issue #32 renaming letsencrypt test server env var 2022-11-10 18:43:50 -03:00
Joao Gilberto
607470a122 Issue #33 - handle networks 2022-11-10 17:43:59 -03:00
Joao Gilberto
9535413a10 Issue #33 2022-11-09 23:57:12 -03:00
Joao Gilberto
79819aeacb issue #32 2022-11-09 18:27:22 -03:00
Joao M
85922425d4 Changes in the Static object 2022-09-02 23:00:16 +00:00
Joao Gilberto Magalhaes
89ab133997 Reload Static 2022-08-30 15:06:07 -05:00
Joao Gilberto Magalhaes
72b40a3c66 Add Listen Port to Ingress 2022-08-28 15:20:16 -05:00
Joao Gilberto Magalhaes
68eea939a3 Fix SSL on Kubernetes 2022-08-26 11:38:02 -05:00
Joao Gilberto Magalhaes
0d16c117cb Fix minor things 2022-08-26 00:50:00 -05:00
Joao Gilberto Magalhaes
912be51399 Added Kubernetes TLS 2022-08-26 00:17:23 -05:00
Joao Gilberto Magalhaes
60bf71f6fb Add annotations to Kubernetes 2022-08-25 20:58:43 -05:00
Joao Gilberto Magalhaes
f007f857df Added more unit tests 2022-08-25 19:37:02 -05:00
Joao Gilberto Magalhaes
733e73ae58 Add log level and test for functions 2022-08-25 17:32:11 -05:00
Joao Gilberto Magalhaes
7d441d6386 adjusting level of debug 2022-08-25 12:30:17 -05:00
Joao Gilberto Magalhaes
50fae1c659 Adjust method parse 2022-08-23 23:04:20 -05:00
Joao Gilberto Magalhaes
5c5f01df2b Using docker python 2022-08-23 23:01:07 -05:00
Joao Gilberto
303d8181f8 Fix factory 2022-08-24 03:02:12 +00:00
Joao M
877a4b3383 More adjustmemts 2022-08-24 02:33:21 +00:00
Joao M
7d959f892a Refactoring to Python 2022-08-24 01:00:26 +00:00