# Store secrets in keystore using ansible

**URL:** <https://discuss.elastic.co/t/store-secrets-in-keystore-using-ansible/268595>\
**Category:** Elasticsearch\
**Created:** [March 28, 2021, 3:33pm UTC](https://discuss.elastic.co/t/store-secrets-in-keystore-using-ansible/268595 "2021-03-28T15:33:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![cruggiero](https://avatars.discourse-cdn.com/v4/letter/c/f475e1/32.png) [@cruggiero](https://discuss.elastic.co/u/cruggiero)\
**Post date:** [March 28, 2021, 3:33pm UTC](https://discuss.elastic.co/t/store-secrets-in-keystore-using-ansible/268595/1 "2021-03-28T15:33:50Z")

</div>

Hello,

I would like to store AWS credentials in the keystore.  
To deploy elasticsearch I used the official ansible playbook.  
Following the documentation I prepared this test node configuration:

```auto
    - hosts: 192.168.172.11
      roles:
        - role: elastic.elasticsearch
      vars:
        es_api_host: 192.168.172.11
        es_heap_size: "8g"
        es_data_dirs:
          - "/elasticsearch/data"
        es_log_dir: "/elasticsearch/logs"
        es_config:
          node.name: "elastic01"
          cluster.name: "name"
          cluster.initial_master_nodes: "192.168.172.11"
          discovery.seed_hosts: "192.168.172.11:9300"
          http.port: 9200
          network.host: 192.168.172.11
          node.data: true
          node.master: true
          bootstrap.memory_lock: false
        es_plugins:
          - plugin: ingest-attachment
          - plugin: repository-s3
        es_keystore_entries:
          - key: s3.client.default.access_key
            value: access_key
            state: present
          - key: s3.client.default.secret_key
            value: secret_key
            state: present

```

but after the playbook run I found only this in the keystore:

```auto
    ./elasticsearch-keystore list -v
    keystore.seed

```

How to troubleshoot this issue ?

Thanks a lot.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 25, 2021, 3:34pm UTC](https://discuss.elastic.co/t/store-secrets-in-keystore-using-ansible/268595/2 "2021-04-25T15:34:25Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
