Skip to main content

Proxy2VPN Python utilities

Project description

Proxy2VPN

Python command-line interface for managing multiple VPN containers with Docker.

Features

  • Manage VPN credentials as reusable profiles
  • Create and control VPN services
  • Bulk start/stop operations
  • Query and validate provider server locations
  • Apply predefined presets for common setups

Installation

Install proxy2vpn from PyPI using your preferred Python tool:

pip

pip install proxy2vpn
proxy2vpn --help

uv

uv tool install proxy2vpn
proxy2vpn --help

uvx

Run the CLI without installing it:

uvx proxy2vpn --help

pipx

pipx install proxy2vpn
proxy2vpn --help

Quick Start

  1. Initialize the compose file:

    proxy2vpn init
    
  2. Create a profile file with your VPN credentials:

    mkdir -p profiles
    cat <<'EOF' > profiles/myprofile.env
    OPENVPN_USER=your_username
    OPENVPN_PASSWORD=your_password
    EOF
    
  3. Register the profile:

    proxy2vpn profile create myprofile profiles/myprofile.env
    
  4. Create and start a VPN service:

    proxy2vpn vpn create vpn1 myprofile --port 8888 --provider protonvpn --location "New York"
    proxy2vpn vpn start vpn1
    
  5. View status and test connectivity:

    proxy2vpn vpn list
    proxy2vpn test vpn1
    

Command overview

Initialization

  • proxy2vpn init [--force]

Profiles

  • proxy2vpn profile create NAME ENV_FILE
  • proxy2vpn profile list
  • proxy2vpn profile delete NAME

VPN services

  • proxy2vpn vpn create NAME PROFILE [--port PORT] [--provider PROVIDER] [--location LOCATION]
  • proxy2vpn vpn list
  • proxy2vpn vpn start NAME
  • proxy2vpn vpn stop NAME
  • proxy2vpn vpn restart NAME
  • proxy2vpn vpn logs NAME [--lines N] [--follow]
  • proxy2vpn vpn delete NAME

Bulk operations

  • proxy2vpn bulk up
  • proxy2vpn bulk down
  • proxy2vpn bulk status
  • proxy2vpn bulk ips

Server database

  • proxy2vpn servers update
  • proxy2vpn servers list-providers
  • proxy2vpn servers list-countries PROVIDER
  • proxy2vpn servers list-cities PROVIDER COUNTRY
  • proxy2vpn servers validate-location PROVIDER LOCATION

Presets

  • proxy2vpn preset list
  • proxy2vpn preset apply PRESET SERVICE [--port PORT]

Testing

  • proxy2vpn test SERVICE – verify that a proxy container is reachable

Development

Setup

# Install with development dependencies
uv sync
# or
pip install -e ".[dev]"

Testing

# Run tests (if available)
pytest

Changelog Management

This project uses Towncrier for changelog management:

# Add a news fragment for your changes
echo "Your feature description" > news/<PR_NUMBER>.feature.md

# Preview the changelog
make changelog-draft

# Build the changelog (maintainers)
make changelog VERSION=x.y.z

License

MIT

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

proxy2vpn-0.2.0.tar.gz (21.7 kB view details)

Uploaded Source

Built Distribution

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

proxy2vpn-0.2.0-py3-none-any.whl (21.3 kB view details)

Uploaded Python 3

File details

Details for the file proxy2vpn-0.2.0.tar.gz.

File metadata

  • Download URL: proxy2vpn-0.2.0.tar.gz
  • Upload date:
  • Size: 21.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for proxy2vpn-0.2.0.tar.gz
Algorithm Hash digest
SHA256 0eb7ea3f4edf8b49ef6724cb84eb24f2dc744edf6124c8e6f80c101605d4feb3
MD5 7dfde450dd785e13dfd38ec42ae52347
BLAKE2b-256 16b38183dcfbe33315fe1be3664a7e3d084871cc42e222b5582cbb54cc36bd7a

See more details on using hashes here.

File details

Details for the file proxy2vpn-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: proxy2vpn-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 21.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for proxy2vpn-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 918477a6aab96077b1687b708c54c6fb9fbb1555cf37ed02eb563bbec56bd187
MD5 cba228ea8a4f4f272f882a5e863e5e91
BLAKE2b-256 0a48962aa8c90625cd701a561b8d71552118bfa2fcb45f24bc6672453bd55e23

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