summaryrefslogtreecommitdiffstats
path: root/ansible_collections/cisco/ise/playbooks/system_certificate.yml
blob: 9986d0ecf2082e4b559b314ed2584889e26bb9ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
---
- hosts: ise_servers
  gather_facts: false
  tasks:
    # - name: Get all
    #   cisco.ise.system_certificate_info:
    #     ise_hostname: "{{ ise_hostname }}"
    #     ise_username: "{{ ise_username }}"
    #     ise_password: "{{ ise_password }}"
    #     ise_verify: "{{ ise_verify }}"
    #   register: result

    # - name: Print all
    #   ansible.builtin.debug:
    #     var: result

    # - name: Get by id
    #   cisco.ise.system_certificate_info:
    #     ise_hostname: "{{ ise_hostname }}"
    #     ise_username: "{{ ise_username }}"
    #     ise_password: "{{ ise_password }}"
    #     ise_verify: "{{ ise_verify }}"
    #     id: d704e911-a916-11eb-8830-2ec507028ea8
    #   register: result

    - name: Get System Certificate by name
      cisco.ise.system_certificate_info:
        ise_hostname: "{{ ise_hostname }}"
        ise_username: "{{ ise_username }}"
        ise_password: "{{ ise_password }}"
        ise_verify: "{{ ise_verify }}"
        ise_debug: "{{ ise_debug }}"
        hostName: ise
      register: result

    - name: Print result
      ansible.builtin.debug:
        var: result

  # - name: Update a system_certificate
  #   cisco.ise.system_certificate:
  #     ise_hostname: "{{ ise_hostname }}"
  #     ise_username: "{{ ise_username }}"
  #     ise_password: "{{ ise_password }}"
  #     ise_verify: "{{ ise_verify }}"
  #     state: present
  #     admin: false
  #     allowReplacementOfPortalGroupTag: false
  #     description: ISE
  #     eap: false
  #     expirationTTLPeriod: 5
  #     expirationTTLUnits: years
  #     hostName: ise
  #     ims: false
  #     name: OU=Certificate Services System Certificate,CN=ise.securitydemo.net#Certificate
  #       Services Endpoint Sub CA - ise#00002
  #     portal: false
  #     portalGroupTag: Default Portal Certificate Group
  #     pxgrid: false
  #     radius: false
  #     renewSelfSignedCertificate: false
  #     saml: false
  #   register: result

  # - name: Print result
  #   ansible.builtin.debug:
  #     var: result