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

k8s inventory - remove trailing slashes from hostname #63

Merged
merged 1 commit into from
Apr 20, 2021

Conversation

Akasurde
Copy link
Member

SUMMARY

When user provides hostname with trailing slashes like
https://localhost:6443/, the openshift library fails to
enumerate the APIs from the given cluster.

This fix removes any extra trailing slashes before sending it
to the openshift DynamicClient.

Fixes: #52

Signed-off-by: Abhijeet Kasurde akasurde@redhat.com

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

changelogs/fragments/52_inventory.yml
plugins/module_utils/common.py

When user provides hostname with trailing slashes like
https://localhost:6443/, the openshift library fails to
enumerate the APIs from the given cluster.

This fix removes any extra trailing slashes before sending it
to the openshift DynamicClient.

Fixes: ansible-collections#52

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
@codecov
Copy link

codecov bot commented Apr 16, 2021

Codecov Report

Merging #63 (7b13661) into main (28223db) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main      #63   +/-   ##
=======================================
  Coverage   23.17%   23.17%           
=======================================
  Files           1        1           
  Lines         151      151           
  Branches       24       24           
=======================================
  Hits           35       35           
  Misses        111      111           
  Partials        5        5           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 28223db...7b13661. Read the comment docs.

@Akasurde Akasurde added this to the 2.0.0 milestone Apr 16, 2021
@abikouo
Copy link
Contributor

abikouo commented Apr 16, 2021

@Akasurde would be nice to add some molecule tests along with

Copy link
Contributor

@alinabuzachis alinabuzachis left a comment

Choose a reason for hiding this comment

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

LGTM.

@Akasurde Akasurde merged commit cc10268 into ansible-collections:main Apr 20, 2021
@Akasurde Akasurde deleted the i52 branch April 20, 2021 07:45
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.

Unable to connect openshift using inventory plugin
4 participants