Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/boutetnico/ansible-role-ssh-keys
Manage SSH keys with Ansible.
https://github.com/boutetnico/ansible-role-ssh-keys
ansible debian keys openssh ssh ubuntu
Last synced: about 3 hours ago
JSON representation
Manage SSH keys with Ansible.
- Host: GitHub
- URL: https://github.com/boutetnico/ansible-role-ssh-keys
- Owner: boutetnico
- License: mit
- Created: 2021-04-01T08:37:19.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-11-05T12:46:39.000Z (4 months ago)
- Last Synced: 2024-12-28T11:16:15.658Z (about 2 months ago)
- Topics: ansible, debian, keys, openssh, ssh, ubuntu
- Language: Python
- Homepage:
- Size: 22.5 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://github.com/boutetnico/ansible-role-ssh-keys/actions?query=workflow%3A%22Test+ansible+role%22)
[](https://galaxy.ansible.com/boutetnico/ssh_keys)ansible-role-ssh-keys
=====================This role installs SSH keys.
Requirements
------------Ansible 2.10 or newer.
Supported Platforms
-------------------- [Debian - 11 (Bullseye)](https://wiki.debian.org/DebianBullseye)
- [Debian - 12 (Bookworm)](https://wiki.debian.org/DebianBookworm)
- [Ubuntu - 22.04 (Jammy Jellyfish)](http://releases.ubuntu.com/22.04/)
- [Ubuntu - 24.04 (Noble Numbat)](http://releases.ubuntu.com/24.04/)Role Variables
--------------| Variable | Required | Default | Choices | Comments |
|--------------------------|----------|-----------------------------|-----------|------------------------------|
| ssh_keys_dependencies | yes | `[openssh-{client,server}]` | list | |
| ssh_keys_authorized_keys | yes | `[]` | list | |
| ssh_keys_known_hosts | yes | `[]` | list | |
| ssh_keys_private_keys | yes | `[]` | list | |
| ssh_keys_public_keys | yes | `[]` | list | |Dependencies
------------None
Example Playbook
----------------- hosts: all
roles:
- role: ansible-role-ssh-keysssh_keys_authorized_keys:
- user: root
src: files/id_rsa.pubssh_keys_known_hosts:
- name: github.com
type: ssh-rsa
key: "AAAAB3NzaC1yc2EAAAADAQABAAABgQCj7ndNxQowgcQnjshcLrqPEiiphnt+VTTvDP6mHBL9j1aNUkY4Ue1gvwnGLVlOhGeYrnZaMgRK6+PKCUXaDbC7qtbW8gIkhL7aGCsOr/C56SJMy/BCZfxd1nWzAOxSDPgVsmerOBYfNqltV9/hWCqBywINIR+5dIg6JTJ72pcEpEjcYgXkE2YEFXV1JHnsKgbLWNlhScqb2UmyRkQyytRLtL+38TGxkxCflmO+5Z8CSSNY7GidjMIZ7Q4zMjA2n1nGrlTDkzwDCsw+wqFPGQA179cnfGWOWRVruj16z6XyvxvjJwbz0wQZ75XK5tKSb7FNyeIEs4TT4jk+S4dhPeAUC5y+bDYirYgM4GC7uEnztnZyaVWQ7B381AK4Qdrwt51ZqExKbQpTUNn+EjqoTwvqNj4kqx5QUCI0ThS/YkOxJCXmPUWZbhjpCg56i+2aB6CmK2JGhn57K5mj0MNdBXA4/WnwH6XoPWJzK5Nyu2zB3nAZp+S5hpQs+p1vN1/wsjk="ssh_keys_private_keys:
- owner: root
group: root
src: files/id_rsa_deploy
dest: /root/.ssh/id_rsa_deployssh_keys_public_keys:
- owner: root
group: root
src: files/id_rsa_deploy.pub
dest: /root/.ssh/id_rsa_deploy.pubTesting
-------molecule test
License
-------MIT
Author Information
------------------[@boutetnico](https://github.com/boutetnico)