# Setting default x-pack user passwords with puppet module

**URL:** <https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172>\
**Category:** Elasticsearch\
**Created:** [May 10, 2017, 12:01am UTC](https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172 "2017-05-10T00:01:17Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![paebersold](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/paebersold/32/18089_2.png) [@paebersold](https://discuss.elastic.co/u/paebersold)\
**Post date:** [May 10, 2017, 12:01am UTC](https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172/1 "2017-05-10T00:01:17Z")

</div>

Hello all,

I'm using the puppet module to manage elasticsearch ([https://forge.puppet.com/elastic/elasticsearch](https://forge.puppet.com/elastic/elasticsearch)) and x-pack. However I can't see how to reset the default x-pack user (elastic/kibana/logstash\_system) passwords. You can't use elasticsearch::user as that adds the user to the x-pack/users file and as the elastic/kibana/logstash\_system users are reserved users this fails.

Thank you.

---

<div class="post-metadata">

**Author:** ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)\
**Post date:** [May 12, 2017, 1:15pm UTC](https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172/2 "2017-05-12T13:15:24Z")

</div>

I'm not really familiar with the Puppet module, but I assume you can run a script from Puppet, so you can do it via cURL request:

curl -k -XPUT --basic "$ESURL/\_xpack/security/user/elastic/\_password?pretty" -H 'Content-Type: application/json' -d'  
{ "password": "changeit" }'

where $ESURL is the URL with the basic auth details added, something like this `username:password@localhost:9200`

---

<div class="post-metadata">

**Author:** ![paebersold](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/paebersold/32/18089_2.png) [@paebersold](https://discuss.elastic.co/u/paebersold)\
**Post date:** [May 15, 2017, 1:11am UTC](https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172/3 "2017-05-15T01:11:31Z")

</div>

Yep that was pretty much where I was (ie a curl command via exec). Just was hoping for a better way that I had missed. Thanks for the reply.

---

<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:** [June 12, 2017, 1:13am UTC](https://discuss.elastic.co/t/setting-default-x-pack-user-passwords-with-puppet-module/85172/4 "2017-06-12T01:13:21Z")

</div>

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