aboutsummaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2017-08-24 02:22:17 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2017-08-29 22:46:14 +0200
commit7fed35a408b9ec37454169425823785b5fc8978b (patch)
tree28371d43ac304f99fb0a5305124858db69ef2137 /manifests
parentba2cf1b5d938810077b0fd73844faf432e8e8f9d (diff)
downloadPuppet-7fed35a408b9ec37454169425823785b5fc8978b.tar.gz
Puppet-7fed35a408b9ec37454169425823785b5fc8978b.tar.zst
Puppet-7fed35a408b9ec37454169425823785b5fc8978b.zip
Refactor base installation module
Diffstat (limited to 'manifests')
-rw-r--r--manifests/install_ovh.pp54
-rw-r--r--manifests/install_ovh_from_scratch.pp18
2 files changed, 3 insertions, 69 deletions
diff --git a/manifests/install_ovh.pp b/manifests/install_ovh.pp
deleted file mode 100644
index a5adf44..0000000
--- a/manifests/install_ovh.pp
+++ /dev/null
@@ -1,54 +0,0 @@
1node default {
2 include stdlib
3
4 stage { 'base_configuration':
5 before => Stage['main']
6 }
7 stage { 'base_installation':
8 before => Stage['base_configuration']
9 }
10 stage { 'preparation':
11 before => Stage['base_installation']
12 }
13
14 class { 'etckeeper':
15 stage => 'preparation'
16 }
17 class { 'ovh_cleanup':
18 stage => 'preparation'
19 }
20 etckeeper::run { 'post_preparation_stage':
21 reason => "Post puppet preparation stage",
22 stages => [Stage['preparation']]
23 }
24
25 class { 'base_packages':
26 stage => "base_installation"
27 }
28 etckeeper::run { 'post_base_installation_stage':
29 reason => "Post puppet base installation stage",
30 stages => [Stage['base_installation']]
31 }
32
33 class { 'locales':
34 stage => "base_configuration"
35 }
36 class { 'cron_puppet':
37 stage => "base_configuration"
38 }
39 class { 'base_configuration':
40 stage => "base_configuration",
41 hostname => 'new.immae.eu'
42 }
43 etckeeper::run { 'post_base_configuration_stage':
44 reason => "Post puppet base configuration stage",
45 stages => [Stage['base_configuration']]
46 }
47
48 class { 'aur': }
49
50 reboot { 'after_run':
51 apply => 'finished',
52 timeout => 0
53 }
54}
diff --git a/manifests/install_ovh_from_scratch.pp b/manifests/install_ovh_from_scratch.pp
index 4888cfc..f5224fa 100644
--- a/manifests/install_ovh_from_scratch.pp
+++ b/manifests/install_ovh_from_scratch.pp
@@ -1,20 +1,8 @@
1node default { 1node default {
2 include stdlib 2 include stdlib
3 3
4 stage { 'base_configuration': } 4 class { 'base_installation':
5 stage { 'base_packages': } 5 stage => "setup",
6 Stage["setup"] 6 grub_device => "/dev/sdb",
7 -> Stage['base_packages']
8 -> Stage['base_configuration']
9 -> Stage['main']
10
11 class { 'base_packages':
12 stage => "base_packages"
13 }
14 class { 'base_configuration':
15 stage => "base_configuration",
16 code_path => "/etc/puppetlabs/code",
17 device => "/dev/sdb",
18 hostname => 'new.immae.eu',
19 } 7 }
20} 8}