Giter Site home page Giter Site logo

ansible-fedora-minimal's Introduction

Fedora Workstation Minimal

This ansible playbook aims to setup a minimal, yet fully featured, instance of Fedora Workstation starting from a minimal netinstall.

Available DE are:

  • GNOME
  • KDE
  • XFCE

Installing the base system

  • Download Fedora Everything ISO Everything ISO
    • TESTED ON:
      • 32
      • 33
      • 34
  • Prepare Boot Media following Install Instructions
  • In the installer under Software Selection, select Minimal Install.
  • Create your user and be sure to mark user as administrator

Running the playbook

The best way to run it is from an external machine (the playbook will reboot the machine a couple of times). Be sure you have ssh access to the target machine.

Run:

./install.sh machine_ip --all,gnome

this will launch the ansible playbook. Wait it to finish.

Tags

Available tags are:

  • powersave (optional) will tweak the system for laptops and install all powersaving features This has to be explicitely specified to be run
  • hardening (optional) will tweak the system for better security This has to be explicitely specified to be run
  • kde (optional) this has to be explicitely specified to be run
  • gnome (optional) this has to be explicitely specified to be run
  • xfce (optional) this has to be explicitely specified to be run

More atomic tags are available:

  • archives
  • base_distro
  • base_packages
  • codecs
  • gnome
  • kde
  • rpmfusion
  • system_tweaks
  • xfce
  • zip

Those will only run the specific task ie. for installing only codecs and rpmfusion, etc.

Running

Locally

So to run all the tags (ie. on a laptop we want Powersaving Tweaks), we will run:

./install.sh MACHINE_IP --tags all,powersave,hardening,gnome

Ansible Pull

It is also possible to use this playbook in ansible-pull mode:

ansible-pull -U https://github.com/89luca89/ansible-fedora-minimal -i $(hostname), -c local --tags all,powersave,hardening,gnome --skip-tags reboot -e "ansible_become_pass=$(pass sudo)" main.yml

Hardening

It's also possible to specify the hardening tag, this will apply various tweaks to improve system security. This work is inspired from:

This phase will:

  • Disable ssh host-based authentication
  • Disable ssh root login
  • Disable coredump storage
  • Mount with noexec,nosuid,nodev as many mountpoints as possible
  • Make /boot and /usr/lib accessible only to root
  • Ensure selinux enforcing
  • Disable root login on any tty
  • Make su binary not accesible to non-sudo users
  • Limit max number of concurrent logins per user
  • Stricter file/folder persmissions in /etc
  • Stricter umask (0027)
  • Stricter $HOME user permissions
  • Sysctl kernel and net values hardening
  • Grub kernel flags hardening

Result:

overview htop kde-overview kde-htop xfce-htop

After install:

  • rpm -qa | wc -l yelds 1248 packages for GNOME, 1375 for KDE, 1211 for XFCE
  • process after boot:
    • 111 GNOME
    • 87 KDE
    • 83 XFCE
  • about 600~650mb of ram occupied after boot (both GNOME and KDE), ~420mb for XFCE

To be noted:

With a minimal install both KDE and GNOME ram consumption is absolutely comparable, if measured with the same tool ( htop ) If we measure with gnome-system-monitor it reports a higher RAM usage for GNOME and at the same time, ksysguard reports much lower RAM usage for KDE, both compared to htop.

So keep in mind that:

  • gnome-system-monitor over reports ram usage
  • ksysguard under reports ram usage

ansible-fedora-minimal's People

Contributors

89luca89 avatar mcpengu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

ansible-fedora-minimal's Issues

Cant add extensions from extensions.gnome.org

When you try to install Gnome Shell extensions from extensions.gnome.org using chrome-gnome-shell on Firefox or Chrome, wont install, even wont show an error but if you check with:

journalctl /usr/bin/gnome-shell

This message appears

Jun 19 15:22:09 laptop.local gnome-shell[1778]: Ignoring excess values in shadow definition
Jun 19 15:22:45 laptop.local gnome-shell[1778]: JS ERROR: GLib.SpawnError: Failed to execute child process “unzip” (No such file or directory)
gotExtensionZipFile@resource:///org/gnome/shell/ui/extensionDownloader.js:89:31
_onInstallButtonPressed/<@resource:///org/gnome/shell/ui/extensionDownloader.js:233:13
Jun 19 15:23:42 laptop.local gnome-shell[1778]: JS ERROR: GLib.SpawnError: Failed to execute child process “unzip” (No such file or directory)
gotExtensionZipFile@resource:///org/gnome/shell/ui/extensionDownloader.js:89:31
_onInstallButtonPressed/<@resource:///org/gnome/shell/ui/extensionDownloader.js:233:13

this can be fixed adding unzip to the install packages. This appears in https://extensions.gnome.org/about/

" I'm using GNOME 3. Why can't I install extensions?
...

Some distributions don't quite package GNOME correctly. Make sure that you have the unzip package installed.

..."

Apart from this, the rest just works perfectly! thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.