Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Chef 12 oc_id regression #1244

Merged
merged 3 commits into from
Apr 27, 2017
Merged

Fix Chef 12 oc_id regression #1244

merged 3 commits into from
Apr 27, 2017

Conversation

stevendanna
Copy link
Contributor

The upgrade of oc_id to Chef 12 in commit

6824d90

introduced 2 issues:

(1) Incorrect arguments to ServrAPI.new
(2) A change in ssl verification behavior

This commit

  • Fixes issue (1),
  • Make the ssl_verify_mode configurable
  • Updates omniauth-chef to a version that contains similar fixes.
  • SSL Verify Mode

The ssl verify mode has been set to verify_none. This isn't a behavior
change from previous versions since this was the default in the old
version of Chef we were previously pinned to.

Because we want to talk to oc_id via 'localhost' to avoid cross-node
requests, changing this to verify_peer is problematic since, even if
we did the work to add /var/opt/opscode/nginx/ca (or the user-provided
cert location) to the trusted_cert_dir, the cert would likely still
mismatch since in the common case such certs ar for the api_fqdn and
not "localhost".

@stevendanna
Copy link
Contributor Author

Depends on chef/omniauth-chef#16

The upgrade of oc_id to Chef 12 in commit

6824d90

introduced 2 issues:

(1) Incorrect arguments to ServrAPI.new
(2) A change in ssl verification behavior

This commit

- Fixes issue (1),
- Make the ssl_verify_mode configurable
- Updates omniauth-chef to a version that contains similar fixes.

* SSL Verify Mode

The ssl verify mode has been set to verify_none. This isn't a behavior
change from previous versions since this was the default in the old
version of Chef we were previously pinned to.

Because we want to talk to oc_id via 'localhost' to avoid cross-node
requests, changing this to verify_peer is problematic since, even if
we did the work to add /var/opt/opscode/nginx/ca (or the user-provided
cert location) to the trusted_cert_dir, the cert would likely still
mismatch since in the common case such certs ar for the `api_fqdn` and
not "localhost".

Signed-off-by: Steven Danna <[email protected]>
gem 'sentry-raven'
gem 'responders', '~> 2.0'
gem 'newrelic_rpm'
gem 'doorkeeper', '~> 1.4.0'

gem 'veil', git: 'https://github.com/chef/chef_secrets'
gem 'omniauth-chef', git: 'https://github.com/chef/omniauth-chef'
gem 'omniauth-chef', git: 'https://github.com/chef/omniauth-chef', branch: 'ssd/POOL-581'
Copy link
Member

Choose a reason for hiding this comment

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

TODO

context "GET /id/v1/status" do
it "retuns 200" do
get(request_url, platform.superuser).should look_like({:status => 200,
:body => {}})
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think we meant for this to be checking against good_status

@stevendanna
Copy link
Contributor Author

@chef/chef-server-maintainers Ready for review.

@stevendanna stevendanna merged commit 7a23bb5 into master Apr 27, 2017
@stevendanna stevendanna deleted the ssd/POOL-581 branch April 27, 2017 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants