Skip to content

Commit c3465a4

Browse files
committed
Update Blog “how-to-use-dscc-api-and-ansible-to-collect-the-storage-configuration”
1 parent 9344456 commit c3465a4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

content/blog/how-to-use-dscc-api-and-ansible-to-collect-the-storage-configuration.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,10 @@ Once you have your client id and client secret, you can generate an access token
3737
The below code example had the client credentials stored in the credentials.yml file, that was encrypted using ansible-vault. The current Ansible playbook stores the access token in a file that grants access only to the current user (hence, the access mode 600 for this file) to avoid misuse of the retrieved access token.
3838

3939
```yaml
40-
- name: Include encrypted vars
40+
name: Include encrypted vars
4141
include_vars: credentials.yml
4242

43-
- name: Get Access Token
43+
name: Get Access Token
4444
ansible.builtin.uri:
4545
url: "{{ sso_url }}"
4646
headers:
@@ -51,11 +51,11 @@ The below code example had the client credentials stored in the credentials.yml
5151
validate_certs: false
5252
register: oauth_response
5353

54-
- name: Define header
54+
name: Define header
5555
ansible.builtin.set_fact:
5656
token: "Bearer {{ oauth_response.json.access_token }}"
5757

58-
- name: Store Token
58+
name: Store Token
5959
ansible.builtin.copy:
6060
content: "{{ token }}"
6161
dest: 'vars/token.txt'

0 commit comments

Comments
 (0)