# I promise you.... I'm pretty smart!!

**URL:** <https://forum.ansible.com/t/i-promise-you-im-pretty-smart/23581>\
**Category:** Ansible Project\
**Created:** [January 27, 2017, 8:42pm UTC](https://forum.ansible.com/t/i-promise-you-im-pretty-smart/23581 "2017-01-27T20:42:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leroy\_Walker\_Jr](https://avatars.discourse-cdn.com/v4/letter/l/c67d28/32.png) [@Leroy\_Walker\_Jr](https://forum.ansible.com/u/Leroy_Walker_Jr)\
**Post date:** [January 27, 2017, 8:42pm UTC](https://forum.ansible.com/t/i-promise-you-im-pretty-smart/23581/1 "2017-01-27T20:42:06Z")

</div>

But I can’t seem to wrap my head around this!

I’ve started working for a new company as a Linux admin. I’ve dabbled in ansible a bit, but in a lab setting.

We have about 300 plus existing servers and I will be building more in the future. This is where Ansible comes in. I would like to use ansible to install stuff onto existing servers if needed and to deploy new ones. The thing I don’t understand is how do I get the SSH keys onto the existing servers and how should I go about putting them on future servers. I know to generate a key and I know how to ssh-copy-id, but this can’t be the best method for 300 servers. Also, should I create my keys as my user or root? I’ve looked and looked, but can’t seem to find a concise answer.

---

<div class="post-metadata">

**Author:** ![Brian\_Coca](https://avatars.discourse-cdn.com/v4/letter/b/6de8d8/32.png) [@Brian\_Coca](https://forum.ansible.com/u/Brian_Coca)\
**Post date:** [January 27, 2017, 8:52pm UTC](https://forum.ansible.com/t/i-promise-you-im-pretty-smart/23581/2 "2017-01-27T20:52:59Z")

</div>

There several ways to do this, Ansible has an authorized\_keys module that can do the copying, the user module can also generate keys. But it does need to log onto the servers, the first time it can use user/password as part of a bootstrapping play.

As for root vs shared user with sudo vs individual users with sudo … it does not matter to Ansible, do what fits your policy and worfklow better. FYI, sudo is not the only privilege escalation method supported, just used as example.
