打开主菜单
首页
随机
登录
设置
关于wrc's Wiki
免责声明
wrc's Wiki
搜索
查看“Isso”的源代码
←
Isso
因为以下原因,您没有权限编辑本页:
您所请求的操作仅限于该用户组的用户使用:
用户
您可以查看和复制此页面的源代码。
Isso 可以用于博客的评论服务。[https://github.com/posativ/isso Github],[https://posativ.org/isso/ 主页] == [[Nginx]] 配置 == <syntaxhighlight lang=nginx> server { server_name isso.example.com; location / { proxy_pass http://unix:/srv/isso/gunicorn.sock; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $host; proxy_set_header X-Forwarded-Proto $scheme; } } </syntaxhighlight> == Isso 配置 == 将 isso 安装在一个 virtualenv 中。<code>requirements.txt</code>: isso gunicorn 注意 isso 0.12.3 和更早的版本和 werkzeug 1.0 不兼容,可在 <code>requirements.txt</code> 中加入 <code>werkzeug==0.16.1</code> 解决。 运行 <syntaxhighlight lang=bash> python3 -m venv venv . ./venv/bin/activate pip install -r requirements.txt </syntaxhighlight> 写一个脚本用于启动 <syntaxhighlight lang=bash> #!/bin/sh set -e cd "$(dirname "$(realpath "$0")")" . ./venv/bin/activate export ISSO_SETTINGS=isso.ini exec gunicorn -b unix:gunicorn.sock isso.run </syntaxhighlight> 写配置文件 <code>isso.ini</code>。不需要邮件提醒可将 <code>notify = smtp</code> 和下面的 <code>[smtp]</code> 一节都去掉。 <syntaxhighlight lang=ini> [general] dbpath = /srv/isso/db.sqlite3 host = https://blog.example.com notify = smtp [smtp] username = blog@example.com password = p@ssw0rd host = smtp.example.com port = 465 security = ssl to = blog@example.com from = "Blog Notification" <blog@example.com> timeout = 10 </syntaxhighlight> == [[Systemd]] 配置 == 再写一个 systemd unit <ref>[https://aur.archlinux.org/cgit/aur.git/tree/isso.service?h=isso isso AUR 包的 <code>isso.service</code>]</ref> <syntaxhighlight lang=ini> # ~/.config/systemd/user/isso.service [Unit] Description=Isso Comment Server After=network.target network-online.target nss-lookup.target [Service] WorkingDirectory=/srv/isso ExecStart=/srv/isso/start.sh [Install] WantedBy=default.target </syntaxhighlight> 启动 systemctl --user enable --now isso.service == 参考资料 == <references /> [[Category:Server]]
返回至
Isso
。