This module provides baselines classes to be picked up and used by many systems.
The ideia is not to apply all classes to all systems, but just agregate in this module the classes that could be used by many systems.
Examples:
- Users
- Repositories
- Timezone and NTP servers
To chocolatey packges to work, put this on site.pp:
if ( $::kernel == 'Windows' ){
Package { provider => 'chocolatey' }
}
Parametarized classes offers a way to reuse code by putting some data outside the class definition.
Hiera is usually used on Puppet, but since we use Foreman, we´ll let Foreman handle these parameters.
That way, we can easily change the root password for a group of hosts or NTP servers for all the hosts just editing a paratmeter in the web interface instead of deploying new configuration throught the entire deploy process.
Manages DNS servers.
Class: infra_baselines::common::dns
OS Support: Linux and Windows.
Parameters (handled by Foreman):
- manage_dns: Whether to manage dns or not.
- dns_servers: Array of DNS servers.
Manages NTP servers.
Class: infra_baselines::common::ntp
OS Support: Linux and Windows.
Parameters (handled by Foreman):
- manage_ntp: Whether to manage ntp or not.
- ntp_servers: Array of NTP servers.
Manages the timezone.
Class: infra_baselines::common::timezone
OS Support: Linux and Windows.
Parameters (handled by Foreman):
- manage_timezone: boolean. To manage timezone or not.
- timezone: the timezone. Specific for each OS. Example: Etc/UTC for Linux is just UTC on Windows.
Ensure vmwaretools is installed and running. Uses open-vm-tools package on Linux and vmware-tools chocolatey package on windows.
Class: infra_baselines::common::vmwaretools
OS Support: Linux and Windows.
No parameters.
Ensure the root user and password.
Class: infra_baselines::linux::users::root
OS Support: Linux
Parameters (handled by Foreman):
- manage_root: boolean. Wherer to manage the host root user or not.
- root_password: String. Hash of the password.
Set some bash customizations like idle timeout, history format, df and dmesg aliases etc.
Class: infra_baselines::linux::custom_profile
OS Support: Linux
Configure some options in inputrc.
Class: infra_baselines::linux::inputrc
OS Support: Linux
No parameters.
Installs and removes some packages.
Class: infra_baselines::linux::packages
OS Support: Linux
List of packages taken from params.pp
Configures some options in the linux puppet agent.
Class: infra_baselines::linux::puppet_agent
OS Support: Linux
Parameters (taken from params.pp):
- puppet_server:
- puppet_runinterval: run interval of the puppet agent. Default is 1800
Installs the RedHat insights agent on RedHat Linuxes.
Class: infra_baselines::linux::redhat_insights
OS Support: RedHat Linux
No parameters
Configures some options on ssh server.
Class: infra_baselines::linux::sshd
OS Support: Linux
Parameters (handled by Foreman):
- sshd_permitrootlogin: whether to permit root login or not.
- sshd_x11forwarding: X11 forwarding.
- sshd_usedns: use reverse dns lookups on client connect.
Make some sysctl tunning.
Class: infra_baselines::linux::sysctl_common
OS Support: Linux
Parameters (handled by Foreman):
- sysctl_kernel_panic: time in seconds to reboot the system after a panic
- sysctl_panic_on_oom: whether to panic when the OOM Killer gets triggered
Provides a simple interface to manage many sysctl tunnings.
Defined type: infra_baselines::linux::sysctl
OS Support: Linux
Parameters:
- sysctl_options: hash of sysctl options
Installs chocolatey package manager.
Class: infra_baselines::windows::chocolatey
OS Support: Windows
No parameters.
Ensure the terminal service is enabled
Class: infra_baselines::windows::rdp
OS Support: Windows
No parameters.
Ensure the winrm is enabled
Class: infra_baselines::windows::winrm
OS Support: Windows
No parameters.
Class to test and fail in case it´s not a Linux system
Class: infra_baselines::check_linux
OS Support: Linux
Class to test and fail in case it´s not a Windows system
Class: infra_baselines::check_windows
OS Support: Windows
Class to provide some default parameters values used by other classes.
Class: infra_baselines::params