8000 Add ansible_win_rm_certificate_thumbprint to facts by rsdoherty · Pull Request #611 · ansible-collections/ansible.windows · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add ansible_win_rm_certificate_thumbprint to facts #611

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

Merged
merged 3 commits into from
May 20, 2024

Conversation

rsdoherty
Copy link
Contributor
SUMMARY

Adds ansible_win_rm_certificate_thumbprint to the facts collected as part of the WinRM facts.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME
  • ansible.windows
ADDITIONAL INFORMATION

Seeing as we're already collecting this data, it would be handy to expose it as a fact for use later (for certificate renewals/updates). Would there be any objections to adding it to the facts like I have implemented below?

PLAY [Test playbook] **********************************************************************************************************************************************************************************************************************************************
TASK [Gathering Facts] ********************************************************************************************************************************************************************************************************************************************
ok: [test-win-vm]

TASK [Print WinRM certificate expiry] *****************************************************************************************************************************************************************************************************************************
ok: [test-win-vm] => {
    "ansible_win_rm_certificate_expires": "2021-11-22 13:17:09"
}

TASK [Print WinRM certificate thumbprint] *************************************************************************************************************************************************************************************************************************
ok: [test-win-vm] => {
    "ansible_win_rm_certificate_thumbprint": "D96A5DC19B1DC6A939BF418B3F48756B0ECC636E"
}

PLAY RECAP ********************************************************************************************************************************************************************************************************************************************************
test-win-vm                 : ok=3    changed=0    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0   

@rsdoherty rsdoherty force-pushed the add-thumbprint-fact branch from 8f6cea2 to 6b4e257 Compare May 17, 2024 16:30
Copy link
Collaborator
@jborean93 jborean93 left a comment

Choose a reason for hiding this comment

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

Thanks for the PR and adding the tests!

@jborean93 jborean93 merged commit 722b05f into ansible-collections:main May 20, 2024
@rsdoherty
Copy link
Contributor Author

No worries! How often are new releases published?

@jborean93
Copy link
Collaborator

I try and aim for one every 2-3 months. There’s no set schedule so it’s a really just when there’s enough to justify a new release.

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
0