Esempio n. 1
0
    def setup(self, scope):
        Schema().upgrade(scope)

        if not self.exists(scope, core.NICKSERV):
            self.log.debug("Creating server account: nick='%s'", core.NICKSERV)

            self.__create_user__(scope,
                                 nick=core.NICKSERV,
                                 password=make_password(8),
                                 is_admin=False)

            password = make_password(8)

        if not self.exists(scope, "admin"):
            self.log.debug("Creating admin account: nick='%s'", core.ADMIN)

            self.__create_user__(scope,
                                 nick=core.ADMIN,
                                 password=password,
                                 is_admin=True)

            self.log.info("Initial admin created with password '%s'." %
                          password)
Esempio n. 2
0
 def setup(self, scope):
     Schema().upgrade(scope)