Code Monkey home page Code Monkey logo

ansible-my-fedora's Introduction

ansible-my-fedora

A simple playbook to automatically configure my Fedora laptop. This role is inspired by: https://gitlab.com/MikkCZ/ansible-fedora

Requirements

After installing fedora, just install ansible and git:

dnf install ansible git -y

install ansible community.general collection:

ansible-galaxy collection install community.general

Clone this repository or install the role from Ansible Galaxy:

git clone https://github.com/yasirsharif/ansible-my-fedora.git

ansible-galaxy install yasirsharif.ansible_my_fedora

Customize the packages to be installed (in defaults/main.yml file) or the configuration (in tasks/desktop-config.yml file) to suit your needs.

Change to the directory where you cloned the repository cd ansbile-my-fedora and dry run:

ansible-playbook test.yml --ask-become-pass --check

if everything works fine, then run:

ansible-playbook test.yml --ask-become-pass --tags update

If you configured sudo without password:

ansible-playbook test.yml --tags dev

Done!

Role Variables

The variables: basic_packages, dev_tools, and sys_tools are defined in defaults/main.yml, you may add or remove packages to these lists as it suits your preferences.

Dependencies

collections: ansible community.general collection

Example Playbook

Below is part of the test.yml file

---
- hosts: localhost
  remote_user: user
  roles:
    - yasirsharif.ansible_my_fedora

License

GPL-3.0 License

Author Information

Yasir ElSharif

@yasirsharif

https://www.linkedin.com/in/yasir-elsharif-8806a343/

ansible-my-fedora's People

Contributors

yasirsharif avatar

Watchers

 avatar

ansible-my-fedora's Issues

couldn't resolve module/action 'community.general.dconf

Hi

when I try your playbook I get this error:

fatal: [localhost]: FAILED! => {"reason": "couldn't resolve module/action 'community.general.dconf'. This often indicates a misspelling, missing collection, or incorrect module path.\n\nThe error appears to be in '.../ansible-my-fedora/tasks/desktop-config.yml': line 13, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: Configure available keyboard layouts in Gnome\n  ^ here\n"}

In fact, you first need to install the corresponding module

ansible-galaxy collection install community.general

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.