OpenFire即时消息服务器上聊天室的HTML存档生成器。

ofarchiver的Python项目详细描述


简介

ofarchiver在 Openfire 即时消息服务器。

示例用法如下:

from ofarchiver import OfArchiver

ofa = OfArchiver()
for room in ofa.get_rooms():
    ofa.gen_archive(room)

还安装了名为ofarchiver的脚本,它利用了 multiprocessing python模块,用于在安装了多个 聊天室。它可以作为cron作业在给定的 间隔。

要求

  • 一个带聊天室的openfire服务器(用3.7.0测试)。
  • mysql作为openfire数据库(用5.0测试)。
  • 一个web服务器(使用apache 2.2及其 mod_autoindex 模块)。
  • Python2.6或更高版本(适用于RHEL/CentOS 5 in EPEL作为 python26)。

安装

  • 使用pip

    sudo pip install OfArchiver
    
  • 使用easy_install

    sudo easy_install OfArchiver
    
  • 来源:

    git clone http://github.com/egnyte/ofarchiver
    cd ofarchiver
    python setup.py build
    sudo python setup.py install
    

配置

明火

Monitoring Service 必须安装并配置OpenFire插件。

  1. 登录到openfire管理面板并选择plugins选项卡。
  2. 安装Monitoring Service插件。
  3. 选择server选项卡,然后选择archiving子选项卡。
  4. 存档设置下,启用存档组聊天

建筑师

包含一个ofarchiver.ini配置文件,该文件必须复制到 下列位置之一(按检查顺序列出):

  • /usr/local/etc
  • /etc
  • 用户的主目录($home

它由以下部分组成(强制选项有一个**):

main

basedir **
The base directory in which to generate the HTML archive.
confserver **
The name of the Openfire conference server.
db **
The type of database used by Openfire (only ^{tt4}$ is currently supported).
debug
Whether to enable debugging statements.
logfile
A file in which to log informational and/or debugging messages.
org
The name of the organization running Openfire.
rooms
A list of rooms for which to generate archives.

分贝

hostname **
The hostname of the MySQL server.
username **
A MySQL user, either Openfire’s or one created just for OfArchiver (only ^{tt5}$ privileges on the ofMessageArchive table is needed).
password **
The password for the MySQL user above.
database **
The MySQL database used by Openfire.

颜色

enabled
Whether to enable colors to more easily differentiate chat room members.
names
A list of colors to choose from.

网络服务器

需要具有自动目录索引生成功能的Web服务器来查看 HTML存档。下面是apache的配置示例 /var/www/html/ofarchive作为存档基目录:

<Directory /var/www/html/ofarchive>
  Options +Indexes
  IndexOptions FancyIndexing
  IndexOrderDefault Descending Date
</Directory>

强烈建议添加身份验证和加密。

谢谢

  • Egnyte因为我允许并鼓励我 发布此软件。

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java如何在JSF中检索DIV宽度   JavaMaven:替换导入为javax和jakarta创建单独的工件   java ModelViewController和应用程序设置   多线程Java线程,具有可视和音频   java Servlet通过Post上传文件   java Google日历API依赖项不起作用   使用多个窗口使用Eclipse进行java调试   java JNI 8 C++:线程附加和分离和异步回调   java将MS Office communicator状态指示器添加到JSP中   java找不到工件javax。指定路径下的jnlp:jnlpapi:jar:5.0   java以编程方式从图像生成像素艺术   java Eclipse IDE使用代理项对处理表情   java层和组件之间的区别是什么?   java使用正弦波进行流畅的转换   为什么我不能在NetBeans调试器中单步进入/跳过Java源代码?