Skip to content

Commit

Permalink
fix: revert bind webrick of consumer server to 0.0.0.0 f1e858e
Browse files Browse the repository at this point in the history
fixes: #89
  • Loading branch information
bethesque committed May 31, 2018
1 parent 0529a67 commit f2ebb6a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/pact/consumer/server.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def get_identity
end

def webrick_opts
opts = {Host: '0.0.0.0', Port: port.nil? ? 0 : port, AccessLog: [], Logger: WEBrick::Log::new(nil, 0)}
opts = { Port: port.nil? ? 0 : port, AccessLog: [], Logger: WEBrick::Log::new(nil, 0) }
opts.merge!({
:SSLCertificate => OpenSSL::X509::Certificate.new(File.open(options[:sslcert]).read) }) if options[:sslcert]
opts.merge!({
Expand Down

4 comments on commit f2ebb6a

@kpse
Copy link
Contributor

@kpse kpse commented on f2ebb6a Dec 14, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May I ask why this get removed? Do we have any other way to access the mock service within the same docker-compose network? @bethesque

@bethesque
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Due to this: #89

@bethesque
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we had to make a few code changes to make the bind address configurable, but it's possible. This fix was just not smart enough.

@kpse
Copy link
Contributor

@kpse kpse commented on f2ebb6a Jan 3, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

making it configurable is definitely a better idea, sadly, I have to lock down my gem version until the feature comes true.
Btw, I reckon binding to 0.0.0.0 isn't that bad given everything lives in containers now.

Please sign in to comment.