Python library to connect to SQLAlchemy with SSH Tunnel
Project description
py-sqlalchemy-ssh-connector
Python library to connect to SQLAlchemy with SSH Tunnel.
Where to get it
The source code is currently hosted on GitHub at: https://github.com/pualien/py-sqlalchemy-ssh-connector
Binary installers for the latest released version are available at the Python package index
pip install sqlalchemy-connector
Example 1
from alchemy_connector import SQLAlchemySession
session = SQLAlchemySession('db.example.com')
result = session.execute('''select * from ecommerce_transactions limit 1''')
session.stop()
# session.start()
Example 2
{adapter}://{username}:{password}@{host}:{port}/{database}
session = SQLAlchemySession(
host='db.example.com',
uri='mysql+pymysql://user:password@127.0.0.1:3306/db'
)
...
session.stop()
Example 3
session = SQLAlchemySession(
host='db.example.com',
user='myuser',
password='mypassword',
)
...
session.stop()
Example 4
session = SQLAlchemySession(
host='db.example.com',
port='21',
user='myuser',
key='/home/myplace/.ssh/id_rsa2',
to_port='37017',
to_host='0.0.0.0'
)
...
session.stop()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for sqlalchemy-connector-0.1.27.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d6ffba3a9b6ab5c3734d7889061e3a459e21a3ccbed6e0e719e12475c67c9147 |
|
MD5 | 60218d0dc55763cdcf5834e255ed04d4 |
|
BLAKE2b-256 | e354327785c56e38cc61f39496ef2f8822a4731e5f63e4c66a475c8595a0ba68 |
Close
Hashes for sqlalchemy_connector-0.1.27-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7028b3a7c9dfd4df17b3e834b718378909c65e67e5b2a731e633e835e540db7a |
|
MD5 | 132992b8d65acfaa8320bca853abcc20 |
|
BLAKE2b-256 | 0091a504f2e344382b4b508a6e9eb4c3ab98d425e10b585a80a9804941315ab3 |