darkwizard242.speedtest

build-test release Ansible Role Ansible Role Ansible Quality Score Quality Gate Status Maintainability Rating Reliability Rating Security Rating GitHub tag (latest SemVer) GitHub repo size

Ansible Role: speedtest

This role installs (by default) the Ookla's Speedtest CLI package or uninstalls it (if specified) on Debian-based and EL-based systems. Speedtest CLI can measure your internet connection speed.

Requirements

No special requirements.

Role Variables

The available variables are listed below (found in defaults/main.yml):

Variables List:

speedtest_app: speedtest
speedtest_app_desired_state: present

# for Debian family
speedtest_debian_pre_reqs:
  - apt-transport-https
  - dirmngr
  - gnupg1
speedtest_debian_pre_reqs_desired_state: present
speedtest_repo_debian_gpg_key: https://packagecloud.io/ookla/speedtest-cli/gpgkey
speedtest_repo_debian: "deb https://packagecloud.io/ookla/speedtest-cli/{{ ansible_distribution | lower }}/ {{ ansible_lsb['codename'] }} main"
speedtest_repo_debian_filename: "{{ speedtest_app }}"
speedtest_repo_debian_keyring_filename: "{{ speedtest_app }}.gpg"
speedtest_repo_debian_keyid: C525F88FCF3A7E56CE2CF59131EB3981E723ACAA
speedtest_repo_debian_desired_state: present

# for EL family
speedtest_repo_el_name: ookla_speedtest-cli
speedtest_repo_el_description: ookla_speedtest-cli
speedtest_repo_el_baseurl: "https://packagecloud.io/ookla/speedtest-cli/el/{{ ansible_distribution_major_version }}/$basearch"
speedtest_repo_el_gpgcheck: no
speedtest_repo_el_gpgkey: https://packagecloud.io/ookla/speedtest-cli/gpgkey
speedtest_repo_el_filename: "{{ speedtest_app }}"
speedtest_repo_el_state: present
speedtest_repo_el_enabled: yes
speedtest_repo_el_filename_owner: root
speedtest_repo_el_filename_group: root
speedtest_repo_el_filename_mode: '0644'

Variables Table:

Variable Description
speedtest_app The name of the Speedtest package to install, e.g., speedtest
speedtest_app_desired_state The state of the speedtest package: install, check if available, or uninstall (options are: present, latest, or absent)
speedtest_debian_pre_reqs Packages recommended for installation on Debian systems.
speedtest_debian_pre_reqs_desired_state Desired state for pre-requisite apps on Debian systems.
speedtest_repo_debian_gpg_key GPG key URL for Debian-based systems.
speedtest_repo_debian Speedtest repository URL for Debian systems.
speedtest_repo_debain_filename Filename for the repository, stored at /etc/apt/sources.list.d/ on Debian systems.
speedtest_repo_debian_keyring_filename GPG key file, stored at /etc/apt/trusted.gpg.d/ on Debian systems (should end with .gpg)
speedtest_repo_debian_keyid Key ID to confirm it hasn't changed.
speedtest_repo_debian_desired_state Indicates creation of the repository file on Debian if it doesn't exist.
speedtest_repo_el_name Name of the Speedtest repository for EL systems.
speedtest_repo_el_description Description for the EL-based repository.
speedtest_repo_el_baseurl Base URL for the Speedtest repository on EL systems.
speedtest_repo_el_gpgcheck Whether or not to perform a GPG check on the repository for EL systems.
speedtest_repo_el_gpgkey GPG key for the Speedtest repository.
speedtest_repo_el_state Indicates creation of the repository file on EL systems if it doesn't exist.
speedtest_repo_el_enabled Whether the Speedtest repository is enabled on EL systems.
speedtest_repo_el_filename Path for saving the Speedtest repository file on EL systems.
speedtest_repo_el_filename_owner Owner of the repository file on EL systems.
speedtest_repo_el_filename_group Group of the repository file on EL systems.
speedtest_repo_el_filename_mode Permissions for the repository file on EL systems.

Dependencies

None

Example Playbook

To install the speedtest package by default in Ansible playbooks:

- hosts: servers
  roles:
    - darkwizard242.speedtest

To customize and install the latest version of speedtest:

- hosts: servers
  roles:
    - darkwizard242.speedtest
  vars:
    speedtest_apps_desired_state: latest

To customize and uninstall the speedtest package:

- hosts: servers
  roles:
    - darkwizard242.speedtest
  vars:
    speedtest_apps_desired_state: absent

License

MIT

Author Information

This role was created by Ali Muhammad.

Informazioni sul progetto

Installs/Uninstalls Ookla Speetest app for internet connection measurement purposes.

Installa
ansible-galaxy install darkwizard242.speedtest
Licenza
mit
Download
5.6k
Proprietario
Senior DevOps/CloudOps Engineer. Dedicated to Automating everything I come across. Love to work on and learn new technologies/tools everyday!