Skip to content

feat: add gateway and DNS fields to pool model (#32)#35

Merged
mgazza merged 1 commit intomainfrom
feat/pool-gateway-dns
Feb 11, 2026
Merged

feat: add gateway and DNS fields to pool model (#32)#35
mgazza merged 1 commit intomainfrom
feat/pool-gateway-dns

Conversation

@mgazza
Copy link
Contributor

@mgazza mgazza commented Feb 11, 2026

Summary

  • Add optional Gateway (string) and DNS ([]string) fields to store.Pool model with json/cbor tags
  • Add ValidateGateway() and ValidateDNS() validation functions: gateway must be a valid IP or empty, each DNS entry must be a valid IP
  • Update PoolRequest, PoolResponse, createPool handler, and poolToResponse to support the new fields
  • Fields are optional for backwards compatibility — empty gateway/dns means "not configured" (BNG falls back to local flags)

Test plan

  • All existing tests pass (go test ./... -count=1)
  • Verify pool creation with gateway and DNS fields via API
  • Verify pool creation without gateway/DNS still works (backwards compatible)
  • Verify invalid gateway/DNS values are rejected with 400

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@mgazza mgazza merged commit 9886bda into main Feb 11, 2026
2 checks passed
@mgazza mgazza deleted the feat/pool-gateway-dns branch February 11, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant