Add functionality to skip TLS verify for mocking HCP in consul #190
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🛠️ Description
When attempting to mock out the HCP api for integration testing for consul the hcp sdk calls out to a specified auth url that has tls enabled. To mock out the HCP bootstrapping and auth token call ( here and here ) we are mocking out HCP fully but are hitting issues with the hcp sdk still verifying the oauth endpoint.
Without this setting we verify the tls settings on the connection to the "authUrl". This allows us to mock the api without concerning the mock with actually having a valid certificate.
This follows the precedence of HCP_API_TLS and HCP_SCADA_TLS settings used for testing. None of these settings are used in a production workload.
🔗 External Links
👍 Definition of Done