Created
June 19, 2014 14:15
-
-
Save flub/b6d20e123a0b568e18a9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
"""Generic host information""" | |
from __future__ import (absolute_import, | |
unicode_literals, print_function, division) | |
import abc | |
def boottime(): | |
"""The time the system booted""" | |
def uptime(): | |
"""Time duration since the system was booted""" | |
def loadavg(): | |
"""The load average for the last 1, 5 and 15 minutes""" | |
################################################################ | |
class HostInfoABC(object): | |
__metaclass__ = abc.ABCMeta |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment