Skip to content

Instantly share code, notes, and snippets.

@rterbush
Last active September 10, 2016 19:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rterbush/dd90b14b2bb4c16b2f476873158459a1 to your computer and use it in GitHub Desktop.
Save rterbush/dd90b14b2bb4c16b2f476873158459a1 to your computer and use it in GitHub Desktop.
install_ssh_deploy_key:
file.managed:
- name: /path/to/deploy.key
- user: deployer
- group: deployer
- mode: 600
- contents_pillar: 'ssh_deploy:key'
ssh_deploy:
key: |
-----BEGIN RSA PRIVATE KEY-----
...
-----END RSA PRIVATE KEY-----
@rterbush
Copy link
Author

rterbush commented Sep 10, 2016

ssh_deploy:
  key: |
      -----BEGIN RSA PRIVATE KEY-----
      ...
      -----END RSA PRIVATE KEY-----

@rterbush
Copy link
Author

Return of pillar.item ssh_deploy:key

web.0.uswest2a.production.lhn:
    ----------
    ssh_deploy:key:
        -----BEGIN RSA PRIVATE KEY-----
        ...
        -----END RSA PRIVATE KEY-----

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment