Masterless Puppet: Connecting a Puppet agent to a central git repo

PuppetMaster

Step-by-step guide

    1. wget https://apt.puppetlabs.com/puppet5-release-xenial.deb
    2. sudo dpkg -i puppet5-release-xenial.deb
    3. sudo apt update
    4. sudo apt install puppet-agent
    5. sudo vim /etc/environment
    6. add /opt/puppetlabs/bin to PATH
    7. source environment
    8. sudo visudo
    9. add /opt/puppetlabs/bin to secure_path
    10. cd ~/.ssh
    11. ssh-keygen
    12. eval `ssh-agent`
    13. ssh-add id_rsa
    14. Copy and Paste the generated public key to your git repo settings
    15. cd /etc/puppetlabs/code/environments
    16. sudo mv production production.sample
    17. sudo git clone [your git repo https url] production
    18. sudo chown -R [your_user:your_group] production
    19. cd production
    20. git remote set-url origin [your git repo ssh url]
    21. git ls-remote
    22. puppet apply manifests
    23. sudo puppet apply manifests

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.