summaryrefslogtreecommitdiffstats
path: root/modules/mysql.py
blob: 2db2817b776bf47e4c8b2543e0e46c8fcdd95f0f (plain)
1
2
3
4
5
6
7
8
9
10
from base import ModuleBase
import MySQLdb

class Module(ModuleBase):
    def __init__(self, manager):
        ModuleBase.__init__(self, manager)
        
        conf = manager.config['mysql']
        
        self.db = MySQLdb.connect(host = conf['host'], user = conf['user'], passwd = conf['passwd'], db = conf['db'], use_unicode = True, charset = 'utf8')