-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfig_vagrant.pp
52 lines (47 loc) · 1.19 KB
/
config_vagrant.pp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# The baseline for module testing used by Puppet Labs is that each manifest
# should have a corresponding test manifest that declares that class or defined
# type.
#
# Tests are then run by using puppet apply --noop (to check for compilation
# errors and view a log of events) or by fully applying the test in a virtual
# environment (to compare the resulting system state to the desired state).
#
# Learn more about module testing here
# <http://docs.puppetlabs.com/guides/tests_smoke.html>
#
#
#
# You can execute this manifest as follows in your vagrant box
#
# sudo puppet apply -t /vagrant/tests/config_vagrant.pp
#
node default {
include bash
Bash::Config {
ensure => 'present',
warn => true,
rootdir => '/home/vagrant',
owner => 'vagrant',
group => 'vagrant',
}
bash::config{ 'aliases':
content => "
# Local aliases
alias cdv='cd /vagrant'
",
}
bash::config{ 'prompts':
content => '
# Local aliases
export PS1="\u@\h \w>"
',
}
bash::config{ 'sysadminrc':
before_hook => true,
content => "
# Load .sysadminrc if present
if [ -f ~/.sysadminrc ]; then
. ~/.sysadminrc
fi",
}
}