Rails IPv6服务器 [英] Rails IPv6 server
问题描述
我正在使用开发服务器,该服务器目前仅具有IPv6连接,并且正在开发Rails应用程序.
I'm using a development server which I currently only have IPv6 connectivity to, and I'm working on a rails application.
我试图使用bundle exec rails s -e development -p 3003 -d
来启动服务器,但似乎只绑定到IPv4:
I tried to use bundle exec rails s -e development -p 3003 -d
to start a server, but it seems it only binds to IPv4:
tcp 0 0 0.0.0.0:3003 0.0.0.0:* LISTEN 27165/ruby
因此我无法连接到它.我最好的选择是什么?我对Rails并不是很熟悉,只是试图解决现有应用程序上的一些问题.
thus I can't connect to it. What's my best option to proceed? I'm not really very familiar with rails just trying to fix a few issues on an existing application.
版本信息:
:; ruby --version
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-linux]
:; rails --version
Rails 3.2.8
推荐答案
我自己弄清楚了,-b ::
将使其监听IPv6和IPv4(可能仅取决于sysctl net.ipv6.bindv6).
Figured it out myself, -b ::
will make it listen on both IPv6 and IPv4 (depending on sysctl net.ipv6.bindv6only probably).
这篇关于Rails IPv6服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!