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.29.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 506e70e316f4cf3fe2059fb9c033049325f184ec8ccc502f3ecf601cf79deb47 |
|
MD5 | d1de004a89d0c12155efcf586faea841 |
|
BLAKE2b-256 | 4ec5ae4581cdc0a8704889da9d6bc75f87a003dade5b4266d5c3a81ef3f62822 |
Close
Hashes for sqlalchemy_connector-0.1.29-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e52250d1f99f83bc3ec8a479029734be99ec0ac5daf8a20554476cd745b1dda9 |
|
MD5 | 5e5c17f7d42192bfaf1dc3bfe59f50dd |
|
BLAKE2b-256 | 6473509916b88f37f016a17b3b5113cebab0f08fe6e585323c0738df42a9dbe5 |