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.41.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | b6e2598f3fe825af1cceb9c34857728e325c7bd4b43309ccb551da8bc89c8f3d |
|
MD5 | f9fd2bccaa95752b39fd90cfc4a01822 |
|
BLAKE2b-256 | abbf961e082fc8254fe4fe4989a45b7dc6584fd8fb5cfcfb2c38a471a4a37a12 |
Close
Hashes for sqlalchemy_connector-0.1.41-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c70fa3487a58a92d691437c42e934073ea74ddf34a14bfc85b30724df28f142b |
|
MD5 | 878d62fc7fbdcc40498469bf1b46aace |
|
BLAKE2b-256 | f215253baa853a8e750b57eba8a5ea9d9f0e853b7d4278c6b7c7c69b41b3258d |