class Middleman::PreviewServer::AllIpv4Interfaces
This is used if bind address is 0.0.0.0, the server name needs to be blank
Public Class Methods
Source
# File lib/middleman-core/preview_server/information.rb, line 149 def self.matches?(opts={}) opts[:bind_address] == '0.0.0.0' && opts[:server_name].blank? end
Public Instance Methods
Source
# File lib/middleman-core/preview_server/information.rb, line 154 def local_network_interfaces network_interfaces_inventory.nil? ? [] : network_interfaces_inventory.network_interfaces(:ipv4) end
Use only ipv4 interfaces
Private Instance Methods
Source
# File lib/middleman-core/preview_server/information.rb, line 160 def after_init @listeners << ServerIpAddress.new('0.0.0.0') end