In this post, you will learn How to install Foreman on Ubuntu/Debian Servers
Foreman is an open-source software which is used for managing the lifecycle of virtual and physical servers. It is a server management tool that helps system administrator to perform configuration, server deployment, provisioning, orchestration and monitoring and more. Foreman offers support for tools like Puppet, Salt Stack, Ansible, Chef. It helps in automating repetitive tasks. It has a great, responsive, full of features WebGUI which makes system administrator to perform tasks more quickly.
Requirements :
- 4GB or more RAM (In terms of provisioning, the more the better)
- 50GB or more (In terms of deploying, the more the better)
- 4vCore CPU or more
- Debian 9 or more or Ubuntu 18.04 or more
Step 1 : Update your Server
First step is to update your server to look for any newer packages or newer security releases for your server
apt-get update -y
apt-get upgrade -y
Step 2 : Set Hostname
Second step is to update your system hostname to a FQDN which resolves to your IP Address
hostnamectl set-hostname foreman.yourdomain.com
nano /etc/hosts
Add your server IP and domain name like the following text or image (Change the IP Address to your own server IP)
10.0.0.1 foreman.yourdomain.com server
Step 3 : Install Foreman
Be default, Foreman is not available in Ubuntu or Debian Servers. So, first we need to install Puppet package Repository in to our server.
Puppet repository for Ubuntu 20.04 :
apt-get update -y
apt -y install ca-certificates gpg -y
wget https://apt.puppet.com/puppet6-release-focal.deb
dpkg -i puppet6-release-focal.deb
Puppet repository for Debian 9 :
apt-get update -y
apt -y install ca-certificates gpg -y
wget https://apt.puppet.com/puppet6-release-stretch.deb
dpkg -i puppet6-release-stretch.deb
Foreman Repository :
echo “deb http://deb.theforeman.org/ focal nightly” | sudo tee /etc/apt/sources.list.d/foreman.list
echo “deb http://deb.theforeman.org/ plugins nightly” | sudo tee -a /etc/apt/sources.list.d/foreman.list
wget -q https://deb.theforeman.org/pubkey.gpg -O- | sudo apt-key add –
Update your server and retrieve the content of Foreman Repository
apt-get update -y
apt-get install foreman-installer
Run the foreman installer :
foreman-installer -i
Then you will see something like this :
This will take 20-30 minutes depending upon your Hard Drive and Network Speed.
After that you can login to your panel running on your domain you set above (foreman.yourdomain.com)
Default Password :
Username : admin
Password : changeme
Conclusion :
You have installed Foreman Provisioning Tool on Ubuntu/Debian Servers. This tutorial is tested on Ubuntu 20.04 and Debian 9. This tutorial assumes you are root!