个性化 Seahub

个性化 Logo 及 CSS 样式

创建 <seafile-install-path>/seahub-data/custom 目录. 在 seafile-server-latest/seahub/media 目录下创建一个符号链接: ln -s ../../../seahub-data/custom custom.

升级过程中,Seafile 升级脚本会自动创建符号链接以维持个性化设置

  1. 将 Logo 文件放在 seafile-server-latest/seahub/media/custom/ 文件夹下
  2. seahub_settings.py 中,重新定义 LOGO_PATH 的值。

    1. LOGO_PATH = 'custom/mylogo.png'
  3. seahub_settings.py 中,重新定义 Logo 宽高的值。

    1. LOGO_WIDTH = 149
    2. LOGO_HEIGHT = 32

个性化 Favicon

  1. 将 favicon 文件放在 seafile-server-latest/seahub/media/custom/ 文件夹下
  2. seahub_settings.py 中,重新定义 FAVICON_PATH 的值。
  1. FAVICON_PATH = 'custom/favicon.png'

自定义 Seahub CSS 样式

  1. seahub/media/custom/ 中新建 CSS 文件,比如: custom.css
  2. seahub_settings.py 中,重新定义 BRANDING_CSS 的值。

    1. BRANDING_CSS = 'custom/custom.css'

个性化 help 页面

首先进入 custom 目录

  1. cd <seafile-install-path>/seahub-data/custom

运行以下命令,将 install.html 文件复制到 custom/templates/help 目录下

  1. mkdir templates
  2. mkdir templates/help
  3. cp ../../seafile-server-latest/seahub/seahub/help/templates/help/install.html
  4. templates/help/

编辑 templates/help/install.html 文件并保存,就可以看到新的 help 页面了。