skip to navigation
skip to content

poseidon 0.3.0

Python library for managing Digital Ocean account

Latest Version: 0.3.1

A library of tools for managing your DigitalOcean account built on top of a Python wrapper for the DigitalOcean API v2

DigitalOcean is known for being developer friendly, I wanted to make it even more so. Here’s a short example to do a test deployment of a Flask app from your github repo (see github for details on how to setup with the right environment variables, DIGITALOCEAN_API_KEY and GITHUB_TOKEN)

import poseidon as P
con = P.connect()
ssh_key_id = con.keys.list()[0]['id']
droplet = con.droplets.create(<domain>, 'sfo1', '512mb',
                              'ubuntu-14-04-x64', ssh_keys=[ssh_key_id])
records =<domain>, droplet.ip_address)
records.create('A', data=droplet.ip_address)
ssh = droplet.connect()
ssh.apt('git python-pip')
ssh.git(username=<username>, repo=<repo_name>)
File Type Py Version Uploaded on Size
poseidon-0.3.0.tar.gz (md5) Source 2014-08-09 8KB