Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/instacart/ahab
Docker event handling with Python
https://github.com/instacart/ahab
Last synced: 3 days ago
JSON representation
Docker event handling with Python
- Host: GitHub
- URL: https://github.com/instacart/ahab
- Owner: instacart
- License: isc
- Created: 2015-11-18T08:08:12.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-11-16T21:54:44.000Z (about 6 years ago)
- Last Synced: 2024-09-25T23:41:00.632Z (3 months ago)
- Language: Python
- Homepage:
- Size: 58.6 KB
- Stars: 138
- Watchers: 127
- Forks: 9
- Open Issues: 1
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
- awesome - instacart/ahab - Docker event handling with Python (others)
- awesome-docker - ahab - Docker event handling with Python by [@instacart](https://github.com/instacart) (Development with Docker / API Client)
- awesome-docker - ahab - Docker event handling with Python by [@instacart](https://github.com/instacart) (Development with Docker / API Client)
README
====
Ahab
====.. image:: ahab.png
It's easy to install Ahab:
.. code:: bash
pip install ahab
To get detailed information about Docker events from the command line:
.. code:: bash
ahab --console debug
To use Ahab as library, you can pass functions to the ``Ahab()`` constructor:
.. code:: python
def f(event, data):
pass # Handle the Docker event (and extended info, as available)ahab = Ahab(handlers=[f])
ahab.listen()Or subclass ``Ahab``:
.. code:: python
class Queequeg(Ahab):
def handle(self, event, data):
pass # Your code here