Skip to main content

Linux system inspection and developer environment audit tool

Project description

dev-audit

CI

Python Version Tests Coverage

Project Status

Current Release: v0.3.0

Features

  • Linux system inspection
  • Resource monitoring
  • Network auditing
  • Developer tool validation
  • Audit findings engine
  • JSON output support
  • Verbose output support
  • Exit code support for automation
  • GitHub Actions CI/CD

Quality Metrics

  • 44 passing tests
  • 50% code coverage
  • Automated CI validation
  • Semantic versioning
  • Tagged releases

A Linux system inspection and diagnostic CLI built for Ubuntu environments.

dev-audit collects system information, resource metrics, network configuration, and developer environment details, then evaluates the results against audit rules to identify potential issues.


Features

System Audit

  • Operating system information
  • Kernel version
  • Hostname
  • Architecture
  • User and shell
  • System uptime

Resource Audit

  • CPU core count
  • Load averages
  • Memory utilization
  • Swap utilization
  • Root filesystem usage

Network Audit

  • Network interfaces
  • Default route
  • DNS configuration
  • Listening TCP and UDP ports

Developer Environment Audit

  • Python
  • pip
  • Git
  • Docker
  • Docker Compose
  • Node.js
  • npm

Audit Engine

Detects:

  • Exposed SSH services
  • HTTP services listening on all interfaces
  • Inconsistent development tool installations
  • WSL-specific tool resolution issues

Output Modes

  • Human-readable terminal output
  • JSON output
  • Verbose diagnostics

Exit Codes

Exit Code Meaning
0 Healthy audit
1 Findings detected
2 Collector failure

Architecture

dev-audit follows a modular collector-based architecture.

CLI
 │
 ├── System Collector
 │      ├── OS Information
 │      ├── Kernel Information
 │      └── Uptime
 │
 ├── Resource Collector
 │      ├── CPU Usage
 │      ├── Memory Usage
 │      ├── Swap Usage
 │      └── Disk Usage
 │
 ├── Network Collector
 │      ├── Interfaces
 │      ├── DNS Servers
 │      ├── Default Route
 │      └── Listening Ports
 │
 ├── DevTools Collector
 │      ├── Python
 │      ├── pip
 │      ├── Git
 │      ├── Docker
 │      ├── Docker Compose
 │      ├── Node.js
 │      └── npm
 │
 └── Audit Engine
        ├── Resource Checks
        ├── Network Checks
        └── Environment Checks

Output Layer
 ├── Human Readable Output
 ├── JSON Output
 └── Exit Codes

Design Goals

  • Modular collector architecture
  • Linux-first implementation
  • Machine-readable JSON output
  • Human-readable terminal output
  • CI/CD validated
  • Test-driven development
  • Suitable for automation and scripting

Example Output

$ dev-audit

System Information
────────────────────────
Hostname      : ubuntu-server
OS            : Ubuntu 24.04 LTS
Kernel        : 6.8.0
Architecture  : x86_64
User          : ubuntu

Resource Usage
────────────────────────
CPU Cores      : 8
Load Average   : 0.10 0.12 0.08

Memory
──────
Total          : 16.0 GiB
Used           : 4.2 GiB
Available      : 11.8 GiB

Audit Findings
──────────────
⚠ SSH is listening on all interfaces.
⚠ HTTP service exposed on all IPv4 interfaces.

JSON Output

$ dev-audit --json
{
  "system": {
    "hostname": "ubuntu-server",
    "kernel": "6.8.0"
  },
  "findings": [
    "SSH is listening on all interfaces."
  ]
}

Use Cases

dev-audit can be used to:

  • Quickly inspect Linux development environments
  • Validate workstation setup before software development
  • Audit servers for exposed services and configuration issues
  • Generate machine-readable JSON reports for automation
  • Troubleshoot networking and developer tool installations
  • Perform lightweight health checks on Ubuntu systems

Installation

Clone Repository

git clone https://github.com/Bonbonjb/dev-audit.git
cd dev-audit

Create Virtual Environment

python3 -m venv .venv
source .venv/bin/activate

Install Package

pip install -e .

Usage

Full Audit

dev-audit

Run Individual Sections

dev-audit system
dev-audit resources
dev-audit network
dev-audit devtools

JSON Output

dev-audit --json

Verbose Output

dev-audit --verbose

Example Audit Findings

⚠ SSH is listening on all interfaces.
⚠ HTTP service exposed on all IPv4 interfaces.
⚠ npm detected but Node.js executable not found.

Running Tests

pytest

Current test suite:

44 passing tests

Project Structure

src/dev_audit/
├── audit.py
├── cli.py
├── command.py
├── output.py
├── status.py
└── collectors/
    ├── system.py
    ├── resources.py
    ├── network.py
    └── devtools.py

tests/
├── test_audit.py
├── test_command.py
├── test_network.py
├── test_output.py
├── test_resources.py
├── test_status.py
└── test_system.py

Roadmap

  • GitHub Actions CI
  • Coverage reporting
  • Additional audit rules
  • Package publishing
  • Extended Linux distribution support

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

devaudit_cli-0.3.0.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

devaudit_cli-0.3.0-py3-none-any.whl (13.5 kB view details)

Uploaded Python 3

File details

Details for the file devaudit_cli-0.3.0.tar.gz.

File metadata

  • Download URL: devaudit_cli-0.3.0.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for devaudit_cli-0.3.0.tar.gz
Algorithm Hash digest
SHA256 6f3b88134031d9b7789e4f41cfdcde158ec23dd3048695a0fb00a12cae498438
MD5 f13bbf3b8db551b7b671e8609cfeac45
BLAKE2b-256 5a2e827f145d5b3890dddf1d19943d82bff5509f865c3deff7e378a0b501742b

See more details on using hashes here.

File details

Details for the file devaudit_cli-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: devaudit_cli-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 13.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for devaudit_cli-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3ee485ec38d97479c0922d096974064c911769ad1169afa32de0fd8034937032
MD5 6b1a2ed62584a8f52734537c73205bf9
BLAKE2b-256 bdd85d4e378ed78783ff2fc284f7d7a458fff89dae785422cfda31767ea93fe8

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