Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
ansible ssl check
---
- hosts: all
connection: local
tasks:
- name: Get a cert from an https port
get_certificate:
host: "www.google.com"
port: 443
register: cert
- copy:
content: "{{ cert.cert }}"
dest: "cert.file"
- name: Ensure that the existing certificate has a certain domain in its subjectAltName
openssl_certificate:
path: "cert.file"
provider: assertonly
subject_alt_name:
- www.example.com
- test.example.com
@kevit
Copy link
Author

kevit commented May 29, 2020

currently have an issue with SNI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment