# Puppet dependencies
ensure_packages(['git', 'puppet'])
+
+ # To run jobs
+ ensure_packages(['at'])
}
class base_installation::services inherits base_installation {
+ if (empty($facts["in_chroot"])) {
+ $ensure = "running"
+ } else {
+ $ensure = undef
+ }
+
service { "sshd":
- #ensure => "running",
+ ensure => $ensure,
enable => true,
}
+ service { "atd":
+ ensure => $ensure,
+ enable => true
+ }
+
service { "systemd-networkd":
- #ensure => "running",
+ ensure => $ensure,
enable => true,
}
service { "systemd-resolved":
- #ensure => "running",
+ ensure => $ensure,
enable => true,
}
service { "systemd-timesyncd":
- #ensure => "running",
+ ensure => $ensure,
enable => true
}
service { "cronie":
- #ensure => "running",
+ ensure => $ensure,
enable => true,
}
pacman-key --populate archlinux
git clone -b $git_branch --recursive https://git.immae.eu/perso/Immae/Projets/Puppet.git $CODE_PATH
+
+export FACTER_in_chroot="yes"
puppet apply --environment $environment --tags base_installation --test $CODE_PATH/manifests/site.pp
# The password seed requires puppet to be run twice
puppet apply --environment $environment --tags base_installation --test $CODE_PATH/manifests/site.pp
environment="$2"
CODE_PATH="/etc/puppetlabs/code"
+export FACTER_in_chroot="yes"
puppet apply --environment $environment --tags base_installation --test $CODE_PATH/manifests/site.pp