• This repository has been archived on 10/Jul/2020
  • Stars
    star
    144
  • Rank 255,590 (Top 6 %)
  • Language
    HTML
  • License
    GNU General Publi...
  • Created almost 12 years ago
  • Updated over 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A place to share templates for various OSes for Foreman's provisioning

This Repository is archived and templates are migrated to the relevant repositories. For more information Click Here.

Community Templates

A place for us to collaborate around templates & snippets for various OSes.

Repo metadata

So that the templates can eventually be updated automatically in Foreman, we are adding metadata to the top of every template. This metadata can be read by a plugin (such as foreman_templates) to determine information abut the template. The metadata is read until the first non-comment line, and contains, the template name, template kind, and any appropriate OS associations. For example:

#kind: user_data
#name: My Userdata
#oses:
# - CentOS 7
# - Debian
# - Ubuntu

Because all the data is contained in the metadata, filenames are arbitrary, however, for consistency we ask that they be grouped appropriately, and end in .erb.

Have a look around the repo for examples.

Testing

There is a test suite available in this repo that tries to render templates using dummy values passing the output to ksvalidator tool which can be found in Fedora and Red Hat repositories as part of pykickstart package and in Ubuntu repositories as part of python-pykickstart package.

You will need ksvalidator from Fedora 20 or later to execute tests. Pykickstart can be installed from git easily too. Use '-l' option to get list of supported versions:

$ ksvalidator -l

To start unit tests do something like:

$ ruby -Itest test/kickstart/provision_test.rb

Another set of tests is in Foreman core git repository, it's possible to run useful render test from the core git repo against this directory:

foreman$ bundle exec rake templates:render DIRECTORY=/path/to/community-templates/provisioning_templates/

It will render selected templates and output can be easily compared via git diff.

Contributing

Please fork and send a pull request. Thanks!

Notes for various templates

CoreOS

The templates use some Host Parameters to contol the flow of the template. These are:

  • install-disk: What device to install to (default: /dev/sda | /dev/vda)
  • ssh_authorized_keys: add public SSH keys which will be authorized for the core user. You can specify multiple SSH keys seperated with a "," (default: empty)
  • etcd_discovery_url: provision a discovery token for etcd to allow a simple cluster deployment. You can get a new discovery token at https://discovery.etcd.io/new. This parameter is used in the coreos_cloudconfig snippet. (default: empty)
  • expose_docker_socket: if you want to have an exposed Docker TCP socket set this to "true"
  • enable_etcd: if you don't require the etcd (and fleet) service, set this to "false" (default: true)
  • reboot-strategy: set the reboot-strategy for CoreOS, for more information have a look at the official documentation

If you don't add any SSH keys you can login with the core user using the root password.

More Information are available on the CoreOS site

Kickstart

Kickstart Files

There is one kickstart and accompanying PXE config, which works for:

Fedora 16 Fedora 17 Fedora 18 Fedora 19 Fedora 20 RHEL, CentOS 5.9 RHEL, CentOS 6.3

Poap

Cisco NX-OS PowerOn Auto Provisioning (POAP) support

More information is available here: http://projects.theforeman.org/issues/10526

Preseed

Tested on:

  • Ubuntu 10.04 (lucid)
  • Ubuntu 12.04 (precise)
  • Ubuntu 13.04 (raring)
  • Ubuntu 14.04 (trusty)
  • Debian 6.0 (Squeeze)
  • Debian 7 (Wheezy)
  • Debian 8 (Jessie)

Host Parameters

The templates use some Host Parameters to control the flow of the template. These are:

  • install-disk: What device to install to (default: the first disk returned with list-devices disk)
  • partitioning-method: regular (default for Preseed default), lvm (default for Preseed default lvm) or crypto
  • partitioning-recipe: atomic (default for Preseed default), home, or multi (default for Preseed default lvm)
  • partitioning-disk-label: If present labels the disk as specified. (Default: automatic/not set. Can be msdos or gpt)
  • partitioning-expert-recipe: Entire recipe (default: empty, i.e partitioning-recipe)
  • partitioning-vg-name: LVM volume group name (default: vg01 for Preseed default lvm)
  • partitioning-filesystem: One of ext4, ext4, btrfs, ... (default: empty, the default is used)
  • partitioning-crypto-erase: Secure erase partition when using crypto method. true or false (default: false)
  • partitioning-crypto-password: Password for luks crypto method. Recommend changing this post install! (default: temporarypassword)
  • partitioning-crypto-password-weak: Allow weak passwords when using crypto. (default: false)
  • partitioning-allow-noswap: Allow partitioning without swap. (default: false)
  • enable-puppet-puppet5: Assume Puppet 5 AIO packages instead of system packages
  • enable-puppet-puppet6: Assume Puppet 6 AIO packages instead of system packages
  • enable-puppetlabs-repo: Add the Puppet Labs repo during install (default: false)
  • enable-puppetlabs-puppet5-repo: Add the Puppet Labs Puppet 5 repo during install (default: false)
  • enable-puppetlabs-puppet6-repo: Add the Puppet Labs Puppet 6 repo during install (default: false)
  • enable-saltstack-repo: Add the SaltStack APT repo to the APT sources during install (default: false)
  • salt_master: SaltStack Master (default: empty)
  • salt_grains: Salt client specific information, like facter (default: empty)
  • preseed-update-policy: Preseed policy for applying updates to running systems. Can be none, unattended-upgrades, or landscape. (default: unattended-upgrades)
  • preseed-live-installer: Informs the installer that the installation source is from an iso. Can be true or false. (defaults: notset/false)
  • preseed-kernel-image: Specify the kernel-image to install. Ex: linux-image-generic-lts-xenial or linux-image-4.4.0-34-generic. (default: empty)
  • preseed-post-install-upgrade: Upgrade Debian post installation. Can be none, safe-upgrade, or full-upgrade. (default: none)

Detailed description is available at https://www.debian.org/releases/stable/amd64/apbs04.html.en

ZTP

Junos Zero-Touch-Provisioning support

More information is available here: http://projects.theforeman.org/issues/3906

License

Copyrights are retained by their owners

This entire repository is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Exceptions

The following file(s) are not licensed under the GPLv3+ as described above and instead contain copyright and license information in their headers:

  • ztp/provision.erb: BSD 2-clause licensed

More Repositories

1

foreman

an application that automates the lifecycle of servers
Ruby
2,398
star
2

foreman_ansible

▢️ Ansible integration in Foreman
JavaScript
211
star
3

smart-proxy

RESTful proxies for DNS, DHCP, TFTP, BMC and Puppet
Ruby
210
star
4

forklift

Helpful deployment scripts for Foreman and Katello
Shell
169
star
5

foreman-ansible-modules

Ansible modules for interacting with the Foreman API and various plugin APIs such as Katello
Python
148
star
6

theforeman.org

The new and improved Foreman website.
HTML
144
star
7

foreman_docker

This plugin enables management of Docker containers and images in Foreman
Ruby
117
star
8

foreman-installer

Automated Foreman installation and configuration
Ruby
116
star
9

foreman_fog_proxmox

Foreman plugin to add Proxmox compute resource based on fog-proxmox gem
Ruby
106
star
10

puppet-foreman

Puppet module for Foreman
Ruby
101
star
11

hammer-cli

Next-gen CLI tool for foreman
Ruby
94
star
12

puppet-puppet

Puppet module for Puppet client and server
Puppet
88
star
13

foreman_bootdisk

ISO and USB boot disk support for Foreman
JavaScript
76
star
14

foreman_ansible_inventory

Foreman dynamic inventory script for ansible - Now merged into Ansible itself
Python
70
star
15

safemode

A library for safe evaluation of Ruby code based on ParseTree/RubyParser and Ruby2Ruby. Provides Rails ActionView template handlers for ERB and Haml.
Ruby
68
star
16

foreman_salt

Foreman plug-in for Salt
Ruby
67
star
17

kafo

A gem for making installations based on puppet user friendly
Ruby
57
star
18

foreman_discovery

A plugin to enable Metal-as-a-Service discovery functionality in foreman
JavaScript
56
star
19

foreman_maintain

The Foreman/Satellite maintenance tool
Ruby
55
star
20

foreman_hooks

Run custom hook scripts on Foreman events
Ruby
53
star
21

puppet-foreman_proxy

Puppet module for Foreman Smart Proxy
Ruby
42
star
22

foreman-discovery-image

Foreman discovery image live distro
Ruby
39
star
23

foreman_openscap

Foreman plug-in for displaying OpenSCAP audit reports
JavaScript
39
star
24

foreman-packaging

Packaging files (RPMs, debs) for Foreman and its dependencies
39
star
25

foreman_templates

A plugin for Foreman to sync provisioning templates from an external source
JavaScript
39
star
26

hammer-cli-foreman

Next-gen CLI tool for foreman (Foreman-specific commands)
Ruby
37
star
27

staypuft

Openstack Foreman Installer
Ruby
34
star
28

puppetdb_foreman

PuppetDB proxy in Foreman
Ruby
32
star
29

foreman-tasks

Tasks management engine and plugin for Foreman
Ruby
31
star
30

foreman-digitalocean

Plugin to enable management of DigitalOcean droplets in Foreman
Ruby
29
star
31

foreman_remote_execution

A plugin bringing remote execution to the Foreman, completing the config management functionality with remote management functionality
JavaScript
29
star
32

foreman-xen

Provision and manage Xen Server in Foreman
Ruby
25
star
33

foreman_dhcp_browser

Web UI browser and editor for DHCP leases
Ruby
24
star
34

foreman-infra

Puppet modules and scripts to manage Foreman project infrastructure
Puppet
23
star
35

foreman_column_view

A simple Foreman plugin showcasing Deface for altering the Hosts view
Ruby
23
star
36

foreman_chef

Foreman extensions that are required for better Chef integration.
JavaScript
22
star
37

foreman_datacenter

This plugin lets you document your physical servers across multiple datacenters
Ruby
21
star
38

chef-handler-foreman

This handler allow Chef to send reports to Foreman
Ruby
20
star
39

foreman-documentation

Documentation for the Foreman Project and its ecosystem
SCSS
19
star
40

ldap_fluff

An LDAP gem for querying LDAP in various styles: Active Directory, FreeIPA & POSIX
Ruby
19
star
41

foreman_monitoring

Foreman plugin for monitoring system integration
Ruby
18
star
42

puppet-dhcp

ISC DHCP server module for Puppet
Ruby
18
star
43

puppet-dns

Installs and manages an ISC BIND DNS server with zones
Ruby
18
star
44

foreman_cockpit

πŸš€ Display console and journal of Cockpit-enabled hosts in Foreman - now replaced by Remote Execution's cockpit integration
Ruby
18
star
45

puppet-pulp

Puppet module for setting up Pulp 2 as part of Katello installation
Ruby
16
star
46

foreman_setup

Plugin for Foreman that helps set up provisioning
Ruby
15
star
47

journald-logger

RubyGem: Logger for systemd-journal
Ruby
15
star
48

smart_proxy_vault

Hashicorp Vault plugin for Smart Proxy
Ruby
14
star
49

foreman_api

[Deprecated][Archived] Ruby bindings for Forman's rest API
Ruby
14
star
50

puppet-foreman_scap_client

Puppet module for OpenSCAP
Ruby
13
star
51

foreman-installer-staypuft

Foreman installer plugin that helps with staypuft Foreman plugin installation
Ruby
13
star
52

puppet-tftp

Puppet module for managing tftp
Ruby
13
star
53

foreman-bats

BATS installation and cli end-to-end testing scripts
Shell
13
star
54

puppet-katello

Puppet module for setting Katello specific configuration. Also includes provider for manipulating with Katello resources.
Ruby
13
star
55

npm2rpm

🎁 Convert npm packages to RPM packages
JavaScript
12
star
56

smart_proxy_dns_infoblox

Ruby
12
star
57

puppet-git

Puppet module for git
Ruby
12
star
58

foreman_host_rundeck

API for Rundeck to pull host data from Foreman
Ruby
12
star
59

foreman_graphite

Send performance metrics to Graphite
Ruby
11
star
60

foreman-selinux

SELinux policy for Foreman
Shell
11
star
61

foreman_default_hostgroup

A plugin to set the default hostgroup when hosts are created.
Ruby
11
star
62

foreman-js

Foreman js tools
JavaScript
10
star
63

foreman-operations-collection

Ansible collection for management of Foreman servers
Makefile
10
star
64

obal

packaging wrapper using ansible
Python
9
star
65

smart_proxy_dns_route53

Route 53 DNS provider plugin for Foreman's smart proxy
Ruby
9
star
66

rfcs

RFCs for TheForeman
9
star
67

foreman_azure_rm

Adds Azure Resource Manager as a compute resource for The Foreman
JavaScript
9
star
68

foreman_memcache

Adds memcache integeration to foreman
Ruby
9
star
69

foreman_kubevirt

Kubevirt as compute resource for Foreman
JavaScript
9
star
70

foreman_pipeline

This project makes Foreman and Jenkins play together nicely. Jenkins can deploy stuff onto newly provisioned hosts by Foreman.
Ruby
9
star
71

smart_proxy_realm_ad_plugin

foreman-proxy realm plugin for Active Directory
Ruby
9
star
72

puppet-passenger

Deprecated puppet module for passenger, use puppetlabs-apache
Ruby
9
star
73

foreman_abrt

Foreman plugin for displaying reports from Automatic Bug Reporting Tool
Ruby
9
star
74

smart_proxy_dhcp_infoblox

foreman smart proxy for dhcp w/ infoblox
Ruby
9
star
75

smart_proxy_remote_execution_ssh

SSH remote execution provider for Foreman smart proxy
Ruby
8
star
76

foreman_omaha

Foreman Plugin to allow CoreOS Updates via Omaha Protocol.
Ruby
8
star
77

foreman_deployments

Plugin to support multi-host deployments
Ruby
8
star
78

smart_proxy_salt

Smart Proxy plug-in for Salt
Ruby
8
star
79

hammer-cli-foreman-ssh

Adds Remote SSH support for Hammer Foreman CLI
Ruby
7
star
80

puppet-apache

Deprecated puppet module for Apache webserver, use the puppetlabs one
Puppet
7
star
81

smart_proxy_dhcp_dnsmasq

dnsmasq DHCP plugin for Foreman smart-proxy
Ruby
7
star
82

foreman_puppet

JavaScript
7
star
83

smart_proxy_monitoring

Smart proxy plugin for monitoring system integration
Ruby
7
star
84

hammer-cli-foreman-admin

Plugin for Hammer CLI for administrative tasks on the Foreman and Smart Proxy servers.
Ruby
6
star
85

foreman-live

kickstart files to build a livecd with foreman pre-installed and configured on boot.
Shell
6
star
86

foreman_rh_cloud

a plugin to Foreman that generates and uploads reports to the Red Hat cloud
Ruby
6
star
87

smart_proxy_ansible

Ansible plugin for smart proxy, with Ansible remote execution provider
Ruby
6
star
88

smart_proxy_dhcp_bluecat

foreman smart proxy plugin for bluecat dhcp
Ruby
6
star
89

puppet-xinetd

Deprecated puppet module for xinetd, use the puppetlabs one
Puppet
6
star
90

smart_proxy_dns_powerdns

Foreman SmartProxy PowerDNS plugin
Ruby
6
star
91

foreman-bootloaders

Binary builds of PXE bootloaders from various Linux distributions
Shell
6
star
92

journald-native

systemd-journal logging interface wrapper for ruby
C
6
star
93

foreman_snapshot

Plugin to handle taking a snapshot of a host group and pushing it back to a Compute Resource as a new image
Ruby
5
star
94

foreman_virt_who_configure

JavaScript
5
star
95

foreman_azure

Old Plugin to have Azure as a Compute Resource in Foreman
Ruby
5
star
96

foreman_expire_hosts

Foreman plugin for limiting host lifetime
Ruby
5
star
97

puppet-certs

Puppet module for dealing with SSL certs across other modules used in Katello
Ruby
5
star
98

hammer_cli_foreman_remote_execution

CLI plugin for Remote Execution
Ruby
5
star
99

foreman_content

A content (Packages and Configuration) management plugin for Foreman
Ruby
5
star
100

smart_proxy_dhcp_remote_isc

Smart Proxy dhcp provider for NFS-accessible ISC dhcpd servers.
Ruby
5
star