Skip to main content

A wrapper for cbttunnels, to make testing local sites easier in CrossBrowserTesting

Project description

cbt_tunnels

A python module to make using tunnels easy.

Note: this is pre-release software. If you encounter any problems, please reach out to CrossBrowserTesting

pip

pip install cbttunnels

How to use

from cbttunnels.cbt_tunnels import CBTtunnel
tunnel = CBTtunnel(username="username", authkey="authkey")
tunnel.start_tunnel()
...
tunnel.kill_tunnel()

Features

  • Automatically gets the correct tunnel for your platform
  • Handles cleanly starting and stopping the tunnel connection
  • Handles all features of the tunnel

Creating a tunnel object

The tunnel object is created with the following options:

  • username ("") - CBT username
  • authkey ("") - CBT authkey
  • delete_after (False) - delete the tunnel binary after kill (note: on Windows, make sure backslashes are escaped \\)
  • tunnel_location (".") - location to download tunnel zip/bianry to
  • ready_file ("ready.check") - ready file for tunnel client
  • kill_file ("kill.check") - kill file for tunnel client

Tunnel options

These are all methods available on the tunnel object

  • bypass(bool) - enable or disable bypass
  • set_https_proxy(string) - string should be the HTTPS proxy
  • set_http_proxy(string) - same as above for HTTP
  • set_tunnel_name(string) - set the name of the named tunnel
  • set_pac_file(string) - set the client to use the PAC file at path string
  • set_html_path(string) - set the path to use for local HTML files to be served
  • set_proxy(host="string", port="string", username="string"/None, password="string/None) - set proxy settings
  • set_accept_all_certs(bool) - set whether to accept all certs in the tunnel client

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

cbttunnels-0.0.3.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

cbttunnels-0.0.3-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file cbttunnels-0.0.3.tar.gz.

File metadata

  • Download URL: cbttunnels-0.0.3.tar.gz
  • Upload date:
  • Size: 4.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.0

File hashes

Hashes for cbttunnels-0.0.3.tar.gz
Algorithm Hash digest
SHA256 5b7eb4a760ad5563288b7a4f0eed07f4688924907be76c39afbc182a95737ae8
MD5 c0c4e9adefe8dd74fade08cd93212e2c
BLAKE2b-256 b801b15095c2f5c35ed3eb14c30e5509a7f8646e45c230583149b6a6fba6e173

See more details on using hashes here.

File details

Details for the file cbttunnels-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: cbttunnels-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 4.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.0

File hashes

Hashes for cbttunnels-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 9c0bb8990f1620bc72e84d17f757f71b7f1e9616c909ca102f62f930a4595cff
MD5 f1c435c9686970b7be239083873d7e4b
BLAKE2b-256 ab9fffaae22086ea605497b74e3f00c7437c1a820030d47f395fc30640ae6576

See more details on using hashes here.

Supported by

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