Arch Linux, as well as Ubuntu already has ruby >2 and puppet 3.3x, so to be able to develop for 2.7.x, I need a local environment. I’ll create it with rbenv.
Prepend your $PATH with ’~/.rbenv/shims’
To build a ssl-enabled puppet, you need openssl development packages before compiling ruby, check this link.
Install a ruby that is known to work with puppet 2.7.x
rbenv install 1.8.7-p375 # make binaries known as shims rbenv rehash # make the new ruby globally rbenv global 1.8.7-p375
Now - after your shell has the correct $PATH,
# /home/xxx/.rbenv/shims/ruby ruby --version # ruby 1.8.7 (2013-12-22 patchlevel 375) [x86_64-linux]
wget http://downloads.puppetlabs.com/facter/facter-1.7.5.tar.gz wget http://downloads.puppetlabs.com/puppet/puppet-2.7.25.tar.gz tar -xzf facter-1.7.5.tar.gz tar -xzf puppet-2.7.25.tar.gz # install facter cd facter-1.7.5 ruby install.rb # if you get an ssl-error, make sure you have the ssl libraries, see above # and start over with compiling ruby cd .. # install puppet cd puppet-2.7.25 # wants to install files to /etc/puppet - thus sudo sudo ~/.rbenv/shims/ruby install.rb rbenv rehash which puppet # /home/xxx/.rbenv/shims/puppet puppet --version # 2.7.25
now you can add syntastic and vim-puppet to vim (I’d suggest to use vundle) and start developing