From 8c81fcd2a2cf455d0e67c91a4e0d774c9e356aa8 Mon Sep 17 00:00:00 2001 From: Bertrand Benjamin Date: Wed, 5 Jan 2022 14:42:16 +0100 Subject: [PATCH] Fix: cleaning --- roles/Vagrantfile | 73 ---------- roles/arch_pkg_install/.travis.yml | 29 ---- roles/arch_pkg_install/.yamllint | 33 ----- roles/arch_pkg_install/README.md | 38 ----- roles/arch_pkg_install/defaults/main.yml | 136 ------------------ roles/arch_pkg_install/handlers/main.yml | 2 - .../molecule/default/INSTALL.rst | 23 --- .../molecule/default/converge.yml | 7 - .../molecule/default/molecule.yml | 11 -- .../tests/__pycache__/conftest.cpython-39.pyc | Bin 982 -> 0 bytes .../__pycache__/test_default.cpython-39.pyc | Bin 609 -> 0 bytes .../molecule/default/tests/conftest.py | 22 --- .../molecule/default/tests/test_default.py | 10 -- roles/arch_pkg_install/tasks/main.yml | 14 -- roles/arch_pkg_install/tests/inventory | 2 - roles/arch_pkg_install/tests/test.yml | 5 - roles/arch_pkg_install/vars/main.yml | 2 - roles/vagrant_playbook.yml | 8 -- 18 files changed, 415 deletions(-) delete mode 100644 roles/Vagrantfile delete mode 100644 roles/arch_pkg_install/.travis.yml delete mode 100644 roles/arch_pkg_install/.yamllint delete mode 100644 roles/arch_pkg_install/README.md delete mode 100644 roles/arch_pkg_install/defaults/main.yml delete mode 100644 roles/arch_pkg_install/handlers/main.yml delete mode 100644 roles/arch_pkg_install/molecule/default/INSTALL.rst delete mode 100644 roles/arch_pkg_install/molecule/default/converge.yml delete mode 100644 roles/arch_pkg_install/molecule/default/molecule.yml delete mode 100644 roles/arch_pkg_install/molecule/default/tests/__pycache__/conftest.cpython-39.pyc delete mode 100644 roles/arch_pkg_install/molecule/default/tests/__pycache__/test_default.cpython-39.pyc delete mode 100644 roles/arch_pkg_install/molecule/default/tests/conftest.py delete mode 100644 roles/arch_pkg_install/molecule/default/tests/test_default.py delete mode 100644 roles/arch_pkg_install/tasks/main.yml delete mode 100644 roles/arch_pkg_install/tests/inventory delete mode 100644 roles/arch_pkg_install/tests/test.yml delete mode 100644 roles/arch_pkg_install/vars/main.yml delete mode 100644 roles/vagrant_playbook.yml diff --git a/roles/Vagrantfile b/roles/Vagrantfile deleted file mode 100644 index 4163d44..0000000 --- a/roles/Vagrantfile +++ /dev/null @@ -1,73 +0,0 @@ -# -*- mode: ruby -*- -# vi: set ft=ruby : - -# All Vagrant configuration is done below. The "2" in Vagrant.configure -# configures the configuration version (we support older styles for -# backwards compatibility). Please don't change it unless you know what -# you're doing. -Vagrant.configure("2") do |config| - # The most common configuration options are documented and commented below. - # For a complete reference, please see the online documentation at - # https://docs.vagrantup.com. - - # Every Vagrant development environment requires a box. You can search for - # boxes at https://vagrantcloud.com/search. - config.vm.box = "archlinux/archlinux" - - # Disable automatic box update checking. If you disable this, then - # boxes will only be checked for updates when the user runs - # `vagrant box outdated`. This is not recommended. - # config.vm.box_check_update = false - - # Create a forwarded port mapping which allows access to a specific port - # within the machine from a port on the host machine. In the example below, - # accessing "localhost:8080" will access port 80 on the guest machine. - # NOTE: This will enable public access to the opened port - # config.vm.network "forwarded_port", guest: 80, host: 8080 - - # Create a forwarded port mapping which allows access to a specific port - # within the machine from a port on the host machine and only allow access - # via 127.0.0.1 to disable public access - # config.vm.network "forwarded_port", guest: 80, host: 8080, host_ip: "127.0.0.1" - - # Create a private network, which allows host-only access to the machine - # using a specific IP. - # config.vm.network "private_network", ip: "192.168.33.10" - - # Create a public network, which generally matched to bridged network. - # Bridged networks make the machine appear as another physical device on - # your network. - # config.vm.network "public_network" - - # Share an additional folder to the guest VM. The first argument is - # the path on the host to the actual folder. The second argument is - # the path on the guest to mount the folder. And the optional third - # argument is a set of non-required options. - # config.vm.synced_folder "../data", "/vagrant_data" - - # Provider-specific configuration so you can fine-tune various - # backing providers for Vagrant. These expose provider-specific options. - # Example for VirtualBox: - # - # config.vm.provider "virtualbox" do |vb| - # # Display the VirtualBox GUI when booting the machine - # vb.gui = true - # - # # Customize the amount of memory on the VM: - # vb.memory = "1024" - # end - # - # View the documentation for the provider you are using for more - # information on available options. - - # Enable provisioning with a shell script. Additional provisioners such as - # Ansible, Chef, Docker, Puppet and Salt are also available. Please see the - # documentation for more information about their specific syntax and use. - # config.vm.provision "shell", inline: <<-SHELL - # apt-get update - # apt-get install -y apache2 - # SHELL - config.vm.provision "ansible" do |ansible| - ansible.playbook = "vagrant_playbook.yml" - end -end diff --git a/roles/arch_pkg_install/.travis.yml b/roles/arch_pkg_install/.travis.yml deleted file mode 100644 index 36bbf62..0000000 --- a/roles/arch_pkg_install/.travis.yml +++ /dev/null @@ -1,29 +0,0 @@ ---- -language: python -python: "2.7" - -# Use the new container infrastructure -sudo: false - -# Install ansible -addons: - apt: - packages: - - python-pip - -install: - # Install ansible - - pip install ansible - - # Check ansible version - - ansible --version - - # Create ansible.cfg with correct roles_path - - printf '[defaults]\nroles_path=../' >ansible.cfg - -script: - # Basic role syntax check - - ansible-playbook tests/test.yml -i tests/inventory --syntax-check - -notifications: - webhooks: https://galaxy.ansible.com/api/v1/notifications/ \ No newline at end of file diff --git a/roles/arch_pkg_install/.yamllint b/roles/arch_pkg_install/.yamllint deleted file mode 100644 index 8827676..0000000 --- a/roles/arch_pkg_install/.yamllint +++ /dev/null @@ -1,33 +0,0 @@ ---- -# Based on ansible-lint config -extends: default - -rules: - braces: - max-spaces-inside: 1 - level: error - brackets: - max-spaces-inside: 1 - level: error - colons: - max-spaces-after: -1 - level: error - commas: - max-spaces-after: -1 - level: error - comments: disable - comments-indentation: disable - document-start: disable - empty-lines: - max: 3 - level: error - hyphens: - level: error - indentation: disable - key-duplicates: enable - line-length: disable - new-line-at-end-of-file: disable - new-lines: - type: unix - trailing-spaces: disable - truthy: disable diff --git a/roles/arch_pkg_install/README.md b/roles/arch_pkg_install/README.md deleted file mode 100644 index 225dd44..0000000 --- a/roles/arch_pkg_install/README.md +++ /dev/null @@ -1,38 +0,0 @@ -Role Name -========= - -A brief description of the role goes here. - -Requirements ------------- - -Any pre-requisites that may not be covered by Ansible itself or the role should be mentioned here. For instance, if the role uses the EC2 module, it may be a good idea to mention in this section that the boto package is required. - -Role Variables --------------- - -A description of the settable variables for this role should go here, including any variables that are in defaults/main.yml, vars/main.yml, and any variables that can/should be set via parameters to the role. Any variables that are read from other roles and/or the global scope (ie. hostvars, group vars, etc.) should be mentioned here as well. - -Dependencies ------------- - -A list of other roles hosted on Galaxy should go here, plus any details in regards to parameters that may need to be set for other roles, or variables that are used from other roles. - -Example Playbook ----------------- - -Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too: - - - hosts: servers - roles: - - { role: username.rolename, x: 42 } - -License -------- - -BSD - -Author Information ------------------- - -An optional section for the role authors to include contact information, or a website (HTML is not allowed). diff --git a/roles/arch_pkg_install/defaults/main.yml b/roles/arch_pkg_install/defaults/main.yml deleted file mode 100644 index 67ee4a9..0000000 --- a/roles/arch_pkg_install/defaults/main.yml +++ /dev/null @@ -1,136 +0,0 @@ ---- -# defaults file for arch_pkg_install - -pacman_base: - - vim - - tmux - - git - - gnupg - -pacman_admin: - - pacman-contrib - - sudo - - wget - - cronie - - ruby - - tig - - openssh - - sshfs - - htop - - ntop - - iotop - - glances - - nmap - - nfs-utils - - samba - - sshpass - - rsync - - autofs - - bind-tools - - unzip - - ntfs-3g - - git-annex - - cifs-utils - - traceroute - - smartmontools - - ripgrep - - fzf - -pacman_cli: - - moc - - pass - - cups - - cups-pdf - - task - - profanity - - neomutt - - youtube-dl - - neovim - - python-pynvim - -pacman_terms: - - rxvt-unicode - - xdotool - - alacritty - -pacman_office: - - gimp - - firefox - - firefox-i18n-fr - - chromium - - inkscape - - pstoedit # Enable latex in inkscape - - thunderbird - - thunderbird-i18n-fr - - libreoffice-fresh - - libreoffice-fresh-fr - - geogebra - - zathura - - zathura-ps - - zathura-djvu - - zathura-cb - - zathura-pdf-mupdf - - scribus - - nextcloud-client - - hunspell - - hunspell-fr - -pacman_work: - - texlive-most - - gnuplot - - auto-multiple-choice - - xournalpp - -pacman_media: - - vlc - - mpv - - mplayer - - guvcview - -pacman_3Dprint: - - openscad - - cura - -pacman_fonts: - - awesome-terminal-fonts - - cantarell-fonts - - gnu-free-fonts - - gsfonts - - ttf-bitstream-vera - - ttf-dejavu - - ttf-droid - - ttf-roboto - - ttf-liberation - - ttf-ubuntu-font-family - - ttf-inconsolata - - noto-fonts - - -pkgs: - - "{{ pacman_base }}" - - "{{ pacman_admin }}" - - "{{ pacman_cli }}" - - "{{ pacman_terms }}" - - "{{ pacman_office }}" - - "{{ pacman_media }}" - - "{{ pacman_work }}" - - "{{ pacman_3Dprint }}" - - "{{ pacman_fonts }}" - -# Packages to install from AUR -aur_fonts: - - ttf-ubuntu-mono-derivative-powerline-git - - ttf-inconsolata-lgc-for-powerline - - ttf-droid-sans-mono-slashed-powerline-git - - ttf-literation-mono-powerline-git - - ttf-opendyslexic - - nerd-fonts-ubuntu-mono - - nerd-fonts-droid-sans-mono - - nerd-fonts-hack - -aur_work: - - perl-locale-codes - -aur_pkgs: - - "{{ aur_fonts }}" - - "{{ aur_work }}" diff --git a/roles/arch_pkg_install/handlers/main.yml b/roles/arch_pkg_install/handlers/main.yml deleted file mode 100644 index 5189914..0000000 --- a/roles/arch_pkg_install/handlers/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -# handlers file for arch_pkg_install diff --git a/roles/arch_pkg_install/molecule/default/INSTALL.rst b/roles/arch_pkg_install/molecule/default/INSTALL.rst deleted file mode 100644 index 0c4bf5c..0000000 --- a/roles/arch_pkg_install/molecule/default/INSTALL.rst +++ /dev/null @@ -1,23 +0,0 @@ -********************************* -Vagrant driver installation guide -********************************* - -Requirements -============ - -* Vagrant -* Virtualbox, Parallels, VMware Fusion, VMware Workstation or VMware Desktop - -Install -======= - -Please refer to the `Virtual environment`_ documentation for installation best -practices. If not using a virtual environment, please consider passing the -widely recommended `'--user' flag`_ when invoking ``pip``. - -.. _Virtual environment: https://virtualenv.pypa.io/en/latest/ -.. _'--user' flag: https://packaging.python.org/tutorials/installing-packages/#installing-to-the-user-site - -.. code-block:: bash - - $ pip install 'molecule_vagrant' diff --git a/roles/arch_pkg_install/molecule/default/converge.yml b/roles/arch_pkg_install/molecule/default/converge.yml deleted file mode 100644 index 388c585..0000000 --- a/roles/arch_pkg_install/molecule/default/converge.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: Converge - hosts: all - tasks: - - name: "Include arch_pkg_install" - include_role: - name: "arch_pkg_install" diff --git a/roles/arch_pkg_install/molecule/default/molecule.yml b/roles/arch_pkg_install/molecule/default/molecule.yml deleted file mode 100644 index 748eb79..0000000 --- a/roles/arch_pkg_install/molecule/default/molecule.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -dependency: - name: galaxy -driver: - name: vagrant -platforms: - - name: instance -provisioner: - name: ansible -verifier: - name: testinfra diff --git a/roles/arch_pkg_install/molecule/default/tests/__pycache__/conftest.cpython-39.pyc b/roles/arch_pkg_install/molecule/default/tests/__pycache__/conftest.cpython-39.pyc deleted file mode 100644 index 2c49c25e172c2be046edb4a4d38d4088419979f5..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 982 zcmZWoPjAyO6t|tUO}lnOXwn3yT#H77#A(umKvO488XX#AXt`Kf?XK<;yVy=gJ9guQ z#CO<^dSPU#q6%g=d#{C>apVkfOu1Ht%w_$B#35c=wr+XHOqDJ-)N zf}t2O%t(qe5)3oMAsEv!2 zthDX*vGe>M4l;nX14 z&S<6>WTGjb@HAd~zPH=mdbQi7JH5kh?_h8Lh;Hxfb_)-JXAjD3W~lO%g&NqEyarlj z4p}gML#)$YD(a4V$*Wk}DSO-1TIr%Xo;pwAn^Q3^h%!Zu%ZboR7M0wJ)WpjPWIF~@ zfFZe#ThHb?G{mX(6K?5HL1W^T8;rT3O$uLFo@pP-|AcfCwjbZ3p~`raCIbz=s571d zUNqs_2qjJQxU!6%v}kwKSL#$i=dI;BGJP%+EtJb7 z1_CTMWTNx)+o7FB0?Obw^sUmAa{?1Qtj@)b`L;T eop7OLPj879*ot6tevO{EYiHa6A2&%r0`C`bMkd|> diff --git a/roles/arch_pkg_install/molecule/default/tests/__pycache__/test_default.cpython-39.pyc b/roles/arch_pkg_install/molecule/default/tests/__pycache__/test_default.cpython-39.pyc deleted file mode 100644 index 326c8e83f0516d647be811d604ea65e56b72a721..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 609 zcmZWnu};G<5Vg|)rBZ=`g{^|A12GaTNC+XZF?0Z_Lzl?Jm)10mE89VowhQ7zVB{zG z3kJNh@C{6yLkk5?I_KWy{LX%7Ua!{(+H?DbzvB1JgGCDvoS>TxTm<1}^m59ZjEzuHunC-jQzrEaRz`7FaYKL4M7yK^v)Z!}g=Y=#XXdk_|_; zr*g#1VBzkNCw<-p!v?5IQe?mqrTP*>Ye6%UK+d&Po=K(>Gv6Yy@p!Q`niIrAYDlco zqv`Z-&73aI`2ha^o;UeL;Ty&RQeI>hujSUuM5$iv6$<@Wyaptw1vR=xwSONi)MzD+ eg-YVMOq4P$EUQ@Lsz(DQ@Y2VA-o_6)tb78EleOUh diff --git a/roles/arch_pkg_install/molecule/default/tests/conftest.py b/roles/arch_pkg_install/molecule/default/tests/conftest.py deleted file mode 100644 index f7ddb3f..0000000 --- a/roles/arch_pkg_install/molecule/default/tests/conftest.py +++ /dev/null @@ -1,22 +0,0 @@ -"""PyTest Fixtures.""" -from __future__ import absolute_import - -import os - -import pytest - - -def pytest_runtest_setup(item): - """Run tests only when under molecule with testinfra installed.""" - try: - import testinfra - except ImportError: - pytest.skip("Test requires testinfra", allow_module_level=True) - if "MOLECULE_INVENTORY_FILE" in os.environ: - pytest.testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner( - os.environ["MOLECULE_INVENTORY_FILE"] - ).get_hosts("all") - else: - pytest.skip( - "Test should run only from inside molecule.", allow_module_level=True - ) diff --git a/roles/arch_pkg_install/molecule/default/tests/test_default.py b/roles/arch_pkg_install/molecule/default/tests/test_default.py deleted file mode 100644 index 0cff669..0000000 --- a/roles/arch_pkg_install/molecule/default/tests/test_default.py +++ /dev/null @@ -1,10 +0,0 @@ -"""Role testing files using testinfra.""" - - -def test_hosts_file(host): - """Validate /etc/hosts file.""" - f = host.file("/etc/hosts") - - assert f.exists - assert f.user == "root" - assert f.group == "root" diff --git a/roles/arch_pkg_install/tasks/main.yml b/roles/arch_pkg_install/tasks/main.yml deleted file mode 100644 index 163cefc..0000000 --- a/roles/arch_pkg_install/tasks/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -# tasks file for arch_pkg_install -- name: Install pkgs - community.general.pacman: - name: "{{ item }}" - state: present - with_items: pkgs - - -- name: Install AUR pkgs - kewlfft.aur.aur: - name: "{{ item }}" - state: present - with_items: aur_pkgs diff --git a/roles/arch_pkg_install/tests/inventory b/roles/arch_pkg_install/tests/inventory deleted file mode 100644 index 878877b..0000000 --- a/roles/arch_pkg_install/tests/inventory +++ /dev/null @@ -1,2 +0,0 @@ -localhost - diff --git a/roles/arch_pkg_install/tests/test.yml b/roles/arch_pkg_install/tests/test.yml deleted file mode 100644 index fe1a62c..0000000 --- a/roles/arch_pkg_install/tests/test.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- hosts: localhost - remote_user: root - roles: - - arch_pkg_install diff --git a/roles/arch_pkg_install/vars/main.yml b/roles/arch_pkg_install/vars/main.yml deleted file mode 100644 index 24c0f55..0000000 --- a/roles/arch_pkg_install/vars/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -# vars file for arch_pkg_install diff --git a/roles/vagrant_playbook.yml b/roles/vagrant_playbook.yml deleted file mode 100644 index bc55977..0000000 --- a/roles/vagrant_playbook.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -- name: Test Vagrant - hosts: all - become: true - roles: - - arch_aur - - users - - gnome