You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "gjing1st (via GitHub)" <gi...@apache.org> on 2026/07/24 09:12:04 UTC

[I] support IPv4/IPv6 dual-stack for admin_listen [apisix]

gjing1st opened a new issue, #13744:
URL: https://github.com/apache/apisix/issues/13744

   ### Description
   
   Problem
   deployment.admin.admin_listen currently only accepts a single {ip, port} object. Attempting the array form (to listen on both IPv4 and IPv6 on the same port):
   ```yaml
   listen:
     - ip: 0.0.0.0
       port: 9180
     - ip: "[::]"
       port: 9180
   ```
   is silently ignored — APISIX falls back to the default 0.0.0.0:9180 (IPv4 only). Verified against current master source:
   
   apisix/cli/ops.lua reads only admin_listen.ip / admin_listen.port scalars
   apisix/cli/ngx_tpl.lua emits a single listen {* admin_server_addr *}; So there is no way to run the Admin API on a dual stack today.
   Root cause
   The address is built as one ip:port string; the template has no loop, and the port-conflict checker rejects reusing one port across addresses.
   
   Proposal
   Make admin_listen accept either the existing object or an array of {ip, port}. The CLI collects all addresses, the template emits one listen per address, and the port-conflict check allows the same port to be reused across addresses of the same service (required for dual-stack). Backward compatible with the single-object form.
   
   Related
   Supersedes / relates to #7972 (IPv6 on control plane, closed as not planned, no fix shipped).
   
   I'd like to contribute a PR with this change plus a CLI test.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org