Skip to the content.

Ansible post install my Fedora

Jacques-Philippe JUBENOT, France

This project "ansible-post-install-my-fedora" is to finish install my Fedora. For each new version of Fedora, I sometimes prefer to reinstall from scratch rather than to make an upgrade.

If it is easy to save datas and restore them, regarding softwares there is always one or more that you forget. You reinstall it or them in emergency at last minute.

Since I discovered Ansible at my office, I found this project was amazing. Imagine and organize installation of your system is possible at home too.

With this project it's possible to finalize the installation of my settings and softwares. GitHub is a fantastic way to share this mini project.

When you reinstall your system, you set your repositories, install softwares and many other things.

My project works like this :

bootstrap: Configure DNF options, and install repositories: RPMFusion, RPMFusion-NON-Free.

disable-ipv6: Disable IPv6.

softwares: A list of my favorites softwares or libraries to install I need …

asbru-cm: Asbru-CM software installation (note that KeePassXC will be installed too).

google-chrome: Install Google-Chrome.

lynis: Install Lynis audit security tool.

vscode: Install Visual-Studio Code.

hb-and-mkmkv-needed-softwares: Install softwares and libraries needed to compile HandBrake and MakeMKV softwares.

handbrake: Compilation of HanBrake software.

makemkv: Compilation of MakeMKV software.

libdvdcss: Permit to read DVD on your computer.

remove-softwares: Remove unnecessary softwares on my fresh installation.

rescue-boot: Recreate your Rescue Boot Menu after many upgrade of your system.

disable-webcam: Disable your webcam support by default when your webcam use uvcvideo driver.

virtualbox: Install VirtualBox virtualization tool.

Important files:

myFedora.yml: This is the playbook which describe the jobs to execute and in which order.

myvars.yml: Define some variables like softwares versions.

!! Pay attention: Modify this file before to execute the Playbook !!

Requirements: It is necessary to install ansible packages.

sudo dnf install ansible

I recommand you to document yourself about Ansible to figure out the philosophy of this product. Like you understand this project will install some softwares and modify your files system, then you need privilegies to execute it.

Be sure, your Fedora system is up-to-date before starting !!

I suggest to create a folder to download the complete script.

mkdir Git-Repo && cd Git-Repo

git clone https://github.com/jpjubenot/ansible-post-install-my-fedora

cd ansible-post-install-my-fedora

If you just want to apply: sudo ansible-playbook myFedora.yml

Good to know.

To list all tasks:

sudo ansible-playbook myFedora.yml --list-tasks

To list all tags:

sudo ansible-playbook myFedora.yml --list-tags

To filter tasks:

sudo ansible-playbook myFedora.yml --list-tasks --tags virtualbox

sudo ansible-playbook myFedora.yml --list-tasks --tags ipv6,fastdnf

To execute tasks using tags:

sudo ansible-playbook myFedora.yml --tags ipv6,fastdnf

If you just want to simulate it without modify your system: sudo ansible-playbook myFedora.yml --check

During this test, you could face errors at this point because some features really need to be installed for the suite.

A test of install will work but if this software is needed in a part of the job, you will face an error because the package is not really present.

With some modifications you can execute this script on a remote computer like in local, look at Ansible documentation and tutorials.

If you want to test for real, it might be worth using it on a virtual machine first, before running it on your personal computer.

The execution time of this script depends of your computer speed and your Internet bandwidth to download all differents packages.