Commit graph

11 commits

Author SHA1 Message Date
Chai Feng
a90e1fbbe9
refactor(test): rename test cases for clarity
The test case names in `ufw-docker-service.test.sh` and `ufw-docker.test.sh` were grammatically incorrect and did not clearly describe their purpose.

This commit renames the test cases to be more descriptive and adhere to the Bach testing framework's conventions, using hyphens to improve readability in the test output.
2025-07-11 17:21:04 +08:00
Chai Feng
b06afc13ef
Support multiple ports in ufw-docker service allow 2025-07-08 16:17:50 +08:00
Chai Feng
7886c73f5b
Extract a function ufw-docker--list-service-ports 2025-07-03 10:27:47 +08:00
Chai Feng
168fc59905
Add IPv6 network support and --docker-subnets option for install/check
- Add support for IPv6 networks in firewall rule generation and validation.
- Add --docker-subnets [SUBNET1 SUBNET2 ...] option to `ufw-docker install` and `ufw-docker check`.
- When used without arguments, automatically detects and applies all Docker network subnets.
- When given subnet arguments, applies firewall rules only to specified subnets (supports multiple subnets, including non-Docker-managed networks).
- If not specified, falls back to default RFC1918 IPv4 and fd00::/8 IPv6 subnets.
- Improve help output with detailed examples and usage guidance.
2025-07-02 18:54:07 +08:00
Chai Feng
6d1c5a229b Add tests for ufw-docker--service-delete 2020-08-12 13:48:01 +08:00
Chai Feng
52fa5dc1e1 Add a test case for ufw-docker--get-env-list 2020-08-12 13:48:01 +08:00
Chai Feng
bac764e44e Add Tests for ufw-docker--service-allow 2020-08-12 13:48:01 +08:00
Chai Feng
9137695937 Fix a test case 2020-08-12 13:48:01 +08:00
Chai Feng
2d2b968024 Add tests for ufw-docker--service-allow, failed scenarios 2020-08-12 13:48:01 +08:00
Chai Feng
5be7dfb366 Add tests for ufw-docker--get-service-{id,name} 2020-08-12 13:48:01 +08:00
Chai Feng
6291251734 Add a new test suite for ufw-docker--service commands 2020-08-12 13:48:01 +08:00