我的配置如下所示:
HAYSTACK_CONNECTIONS = {
'default': {
'ENGINE': 'haystack.backends.whoosh_backend.WhooshEngine',
'PATH': os.path.join(BASE_DIR, "fulltext_index"),
...我已经安装了2.7.4。但是我的fulltext_index目录只包含一个文件,_MAIN_0.toc,它已经两年没有更新了。
这里会发生什么事?据推测,Hyperkitty应该在对新消息进行归档时索引它们。我现在可以运行update_index来修复索引,但是它会再次过时。
发布于 2022-10-18 20:06:01
Hyperkitty通过定期作业更新索引。您应该在例如/etc/cron.d/mailman中添加以下内容
@hourly mailman /opt/mailman/venv/bin/mailman-web runjobs hourly
@daily mailman /opt/mailman/venv/bin/mailman-web runjobs daily
@weekly mailman /opt/mailman/venv/bin/mailman-web runjobs weekly
@monthly mailman /opt/mailman/venv/bin/mailman-web runjobs monthly
@yearly mailman /opt/mailman/venv/bin/mailman-web runjobs yearly
* * * * * mailman /opt/mailman/venv/bin/mailman-web runjobs minutely
2,17,32,47 * * * * mailman /opt/mailman/venv/bin/mailman-web runjobs quarter_hourly这个片段是从页面中提取的。
https://docs.mailman3.org/en/latest/config-web.html#scheduled-tasks-required
还可以在包含以下crontab示例的Hyperkitty中检查一个示例项目
# This goes in /etc/cron.d/.
# Replace "apache" by your webserver user ("www-data" on Debian systems) and
# set the path to the Django project directory
@hourly apache django-admin runjobs hourly --pythonpath /path/to/project --settings settings
@daily apache django-admin runjobs daily --pythonpath /path/to/project --settings settings
@weekly apache django-admin runjobs weekly --pythonpath /path/to/project --settings settings
@monthly apache django-admin runjobs monthly --pythonpath /path/to/project --settings settings
@yearly apache django-admin runjobs yearly --pythonpath /path/to/project --settings settings
# Currently Hyperkitty has no minutely and quarter_hourly jobs. The purpose of
# the next lines is to ease the upgrading process, in the eventual case that
# Hyperkitty will utilize minutely or quarter_hourly jobs.
2,17,32,47 * * * * apache django-admin runjobs quarter_hourly --pythonpath /path/to/project --settings settings
* * * * * apache django-admin runjobs minutely --pythonpath /path/to/project --settings settingshttps://stackoverflow.com/questions/74055901
复制相似问题