Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $bar = 'bar'
- class foobar {
- exec { 'foobar':
- command => "export Foo=${bar}",
- }
- }
- Exec { environment => [ "foo=$bar" ] }
- class example($somevar) {
- file { "/etc/environment":
- content => inline_template("SOMEVAR=${somevar}")
- }
- }
- $bar = 'bar'
- file { "/etc/profile.d/my_test.sh":
- content => "export Foo=${bar}",
- mode => 755
- }
- class foobar {
- exec { 'foobar' :
- command => "/bin/bash -c "export Foo=${bar}"",
- }
- }
- $PS1 = '[e[0;31m]u[e[m] [e[1;34m]w[e[m] $ '
- exec {"vagrant-prompt":
- unless => "grep -F 'export PS1="${PS1}"' ${HOME_DIR}/.bashrc",
- command => "echo 'export PS1="${PS1}"' >> ${HOME_DIR}/.bashrc",
- user => "${APP_USER}",
- }
- file_line { "foo_env_var":
- ensure => present,
- line => "Foo=${bar}",
- path => "/etc/environment",
- }
Add Comment
Please, Sign In to add comment