diff options
author | Roald de Vries <rdevries@thoughtworks.com> | 2016-09-22 17:29:58 +0200 |
---|---|---|
committer | Roald de Vries <rdevries@thoughtworks.com> | 2016-09-22 17:29:58 +0200 |
commit | 3db89b8929e5cc782382b4b89001a968f959cfd1 (patch) | |
tree | f297de1349507e9e2833caa302aa17d8b1ab21a9 /service/pixelated | |
parent | a42e2fb603f9f1b82bb18e1636a64eb3bf518884 (diff) |
move loglinegenerator to the support package
Diffstat (limited to 'service/pixelated')
-rw-r--r-- | service/pixelated/application.py | 5 | ||||
-rw-r--r-- | service/pixelated/support/loglinegenerator.py | 7 |
2 files changed, 8 insertions, 4 deletions
diff --git a/service/pixelated/application.py b/service/pixelated/application.py index 30e1bd3a..90a179f0 100644 --- a/service/pixelated/application.py +++ b/service/pixelated/application.py @@ -41,7 +41,7 @@ from pixelated.config.site import PixelatedSite from pixelated.resources.auth import LeapPasswordChecker, PixelatedRealm, PixelatedAuthSessionWrapper, SessionChecker from pixelated.resources.login_resource import LoginResource from pixelated.resources.root_resource import RootResource -from loglinegenerator import ILogLineGenerator +from pixelated.support.loglinegenerator import ILogLineGenerator log = logging.getLogger(__name__) @@ -213,9 +213,6 @@ def start_site(config, resource): if config.manhole: log.info('Starting the manhole on port 8008') - passwdFile = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'passwd') - namespace = globals() - multiService = manhole_tap.makeService(dict(namespace=globals(), telnetPort='8008', sshPort='8009', diff --git a/service/pixelated/support/loglinegenerator.py b/service/pixelated/support/loglinegenerator.py new file mode 100644 index 00000000..3b7820fb --- /dev/null +++ b/service/pixelated/support/loglinegenerator.py @@ -0,0 +1,7 @@ +from zope.interface import Interface + + +class ILogLineGenerator(Interface): + def getLogLine(self): + """ Return a string that will be logged, or None. This method will be called every second. + """ |