Skip to content

Instantly share code, notes, and snippets.

@Tom-Millard
Created September 29, 2016 09:09
Show Gist options
  • Save Tom-Millard/8b4c813616a98af42a2e9e805733daf6 to your computer and use it in GitHub Desktop.
Save Tom-Millard/8b4c813616a98af42a2e9e805733daf6 to your computer and use it in GitHub Desktop.
Install node on CentOS 7 with puppet
#BEGIN - Install node.js
package { 'gcc-c++':
ensure => 'installed',
}
package { 'make':
ensure => 'installed',
}
exec { 'setup-node':
command => 'curl -sL https://rpm.nodesource.com/setup_6.x | sudo -E bash -',
require => [Package['curl'], Package['gcc-c++'], Package['make']],
path => '/usr/bin:/usr/sbin:/bin',
unless => 'ls /usr/bin/ | grep node'
}
package { 'nodejs':
ensure => 'installed',
}
#END
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment