poseidon: tame the digital ocean
Python library for managing your Digital Ocean account
The DigitalOcean API allows you to manage Droplets and resources within the DigitalOcean cloud in a simple, programmatic way using conventional HTTP requests. The endpoints are intuitive and powerful, allowing you to easily make calls to retrieve information or to execute actions.
This library starts with a python wrapper for the API and aims to build tools to make it easier to manage, provision, and deploy to Digital Ocean.
Highlights
Full featured: API wrapper covering the published DigitalOcean API v2
Tested: integration test coverage against most of the API
SSH integration: integrates paramiko library so you can SSH in and issue commands
Deployment conveniences: methods like apt, pip, and git for easier deployment
Example
Deploy a new Flask app from github
import poseidon as P
client = P.connect()
ssh_key_id = client.keys.list()[0]['id']
droplet = client.droplets.create('example.changshe.io', 'sfo1', '512mb',
'ubuntu-14-04-x64', ssh_keys=[ssh_key_id])
domain = client.domains.create('example.changshe.io', droplet.ip_address)
records = client.domains.records(domain['name'])
records.create('A', data=droplet.ip_address)
ssh = droplet.connect()
ssh.apt('git python-pip')
ssh.git(username='changhiskhan', repo='hello_world')
ssh.chdir('hello_world')
ssh.pip_r('requirements.txt')
ssh.nohup('python app.py') # DNS takes a while to propagate
print ssh.ps()
Metadata
Release files for poseidon 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| poseidon-0.3.1.tar.gz | 11.6 kB | Without provenance | Details for poseidon-0.3.1.tar.gz |
Release files / poseidon-0.3.1.tar.gz
| Download URL | poseidon-0.3.1.tar.gz |
|---|---|
| Size | 11.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a567c5b5ab6cd23857754b734b014cafee2053c31ca5171615f0752188e600d5
|
|
BLAKE2b-256 checksum How to use checksums |
6af32d69dd0cfedb83e1865e9940dde829bc61071562f62334e23927a974a68d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for poseidon 0.3.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.