Skip to main content

A lightweight command-line tool for testing connectivity to web sources over various protocols (HTTPS, DNS, etc).

This project has been archived.

The maintainers of this project have marked this project as archived. No new releases are expected.

Project description

Connectivity Tool CLI

Latest Release PyPI version License DockerHub

connectivity-tool Coverage Status

Welcome to the Connectivity Tool CLI, a command-line interface for network connectivity operations.

📦 Features

With the Connectivity Tool CLI, you can perform the following operations:

  • Ping - Check the reachability of a host / URL
  • Performance - Check the performance of a URL (latency download/upload bandwidth)
  • Deviation - Trace deviations of the response time of a host / URL

🌐 Supported Protocols

  • DNS
  • HTTPS
  • HTTP

📋 Requirements

Python 3.10 or Docker

⬇️ CLI Download

To start using this CLI, install it via PIP (PyPi registry) as a global python command

pip install connectivity_tool

Note: The CLI also available as a Docker image, see Docker Hub For more information, see the Docker section

🚀 Getting started

Before starting, run the help command to understand how to pass the operation's parameters and payload with all the available options.

connectivity_tool --help

📚 Usage Examples

⚡ Direct params

connectivity_tool -p DNS -d yahoo.com

📂 Test suite path

connectivity_tool --suite-file ./suite.yaml

The file structure should be as follows:

suite:
  - protocol: DNS
    domain: "yahoo.com"

  - protocol: HTTP
    url: "http://www.google.com"

  - protocol: HTTPS
    url: "https://www.facebook.com"
    latency_threshold_deviation: # Optional for HTTP/HTTPS only - default is 60 seconds
      value: 1 # Amount of units
      unit: Millisecond # Unit of the value (e.g. Millisecond, Second, Minute)
    test_upload_bandwidth: true # Optional for HTTP/HTTPS only - default is false
    test_download_bandwidth: true # Optional for HTTP/HTTPS only - default is false

The json format is also supported as yaml is the default format, set also -t json argument to specify format.

{
  "suite": [
    {
      "protocol": "DNS",
      "domain": "yahoo.com"
    },
    {
      "protocol": "HTTP",
      "url": "http://www.google.com"
    },
    {
      "protocol": "HTTPS",
      "url": "https://www.facebook.com",
      "latency_threshold_deviation": {
        "value": 1,
        "unit": "Millisecond"
      },
      "test_upload_bandwidth": true,
      "test_download_bandwidth": true
    }
  ]
}

🗃️ Results Store

Every operation result will be stored in a jsonl local file.

Run connectivity_tool --output-store 5 to print to stdout the last 5 result/s.

The store file is ./store_data/conn_tool_store.jsonl as default and can be changed by --store flag.

For Docker see the Docker section

🔍 Troubleshooting and logging

The full version and build info of the CLI is available by --info see example:

connectivity_tool --info

Connectivity Tool Cli allows to print verbose logs.

connectivity_tool --verbos

🐞 Report Bug

In case of an issue or a bug found in the CLI, please open an issue

🛠️ Development & Contribution

See the Development section for more information

📝 License

The Connectivity Tool CLI is licensed under the MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

connectivity_tool-1.0.13.tar.gz (17.8 kB view details)

Uploaded Source

File details

Details for the file connectivity_tool-1.0.13.tar.gz.

File metadata

  • Download URL: connectivity_tool-1.0.13.tar.gz
  • Upload date:
  • Size: 17.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.15

File hashes

Hashes for connectivity_tool-1.0.13.tar.gz
Algorithm Hash digest
SHA256 cb4c52c265378a3c06b2993d8e7f969d77fc6f7e73c88e3fb893dfa0086cb64d
MD5 39d8342a4ea0db44a2d35d6eb93acafc
BLAKE2b-256 fda9abdfcd6c7a7a78f4e2660e1c9cfcb294e741662860a8428077413b1e1608

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page