我"iptables": false在 docker daemon config 中的用户选项:
/etc/docker/daemon.json:
{
"iptables": false
}
我使用选项运行服务--publish mode=host,--mode=global类似于这种方法。
但是当我X-Real-IP在我的应用程序中获取标题时,它的值是172.18.0.1但不是真正的用户 ip。
当我启动 Docker 守护程序时"iptables": false,/etc/docker/daemon.json一切正常,我得到了真正的用户 ip。
但我需要设置"iptables": false为使用 Docker 保留 iptables 更改。
"iptables": false是否可以在 Docker 守护程序配置中获取真实用户 ip ?