You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

114 lines
3.6 KiB

seafile-server: Update to 7.1.2, revamp package * Package scripts that are shipped by upstream in their binary download * Includes setup scripts (setup-seafile.sh to use SQLite, setup-seafile-mysql.{sh,py} to use MySQL) and control scripts (seafile.sh, seahub.sh) * Does not include seafile-admin, which is not shipped in upstream's binary download. Combined with the fact that it hasn't been updated to Python 3 suggests the script has been abandoned. * Replace previous init scripts with a simplified script * Previous init scripts (seafile.init, seahub.init) were modified from older versions of seafile.sh and seahub.sh, but they haven't kept up with changes to upstream's scripts * New init script (seafile-server.init) start/stops both Seafile and Seahub (there is no need to control them separately) by calling upstream's control scripts * Replace previous package config file with new config file * Options in previous config file (seafile.conf) were mainly for using Seahub in FastCGI mode. FastCGI was deprecated in Django 1.7 and removed in 1.9; upstream's control script will only start Seahub using Gunicorn. (Options for Gunicorn including port number can be changed by editing /etc/seafile/conf/gunicorn.conf.py.) * New config file (seafile-server.config) has one option that controls where the Seafile/Seahub data directories are stored * Patch scripts/binaries to use standard, system-wide directory locations * Script files (wrappers for binaries) in /usr/bin * Binaries (not meant to be run directly by the user) in /usr/libexec * Config files in /etc/seafile * Pid/socket files in /var/run/seafile * Logs in /var/log/seafile * Include a new script to create the first admin account * With upstream's original scripts, the user is required to interactively create the first admin account when Seahub is started for the first time * The user will now use the new script (create-seafile-admin.sh) to create the first admin account after setup (using setup-seafile.sh or setup-seafile-mysql.sh) and before starting Seafile/Seahub * seahub.sh is patched to only check if there is at least one admin account and exit with an error if there is no admin account * Remove build config options and add seafile-server-fuse package * The console option controls whether the console window is shown when Seafile server is run on Windows. It has no use on Linux. * The fuse option controls whether seaf-fuse is built. (seaf-fuse is a FUSE implementation that allows the Seafile database/file system to be mounted to a local directory.) seaf-fuse is now always built and is available in a separate package (seafile-server-fuse). * Add myself as a maintainer Signed-off-by: Jeffery To <jeffery.to@gmail.com>
5 years ago
  1. # Seafile Server on OpenWrt
  2. ## Installation Notes
  3. ### First-time Installation
  4. 1. Consider where you would like the Seafile data directory
  5. (`seafile-data`), Seahub data directory (`seahub-data`), and the
  6. Seahub database (`seahub.db`, if you will be using SQLite) to be
  7. stored.
  8. This location can be configured in `/etc/config/seafile-server`
  9. (using the _data_dir_ option); the default is `/usr/share/seafile`.
  10. If you are certain you will use a custom location, set this location
  11. in `/etc/config/seafile-server` before continuing with the other
  12. installation steps.
  13. 2. Run one of the two setup scripts:
  14. * To use SQLite:
  15. # setup-seafile
  16. * To use MySQL:
  17. # setup-seafile-mysql
  18. 3. Create a Seafile admin account:
  19. # create-seafile-admin
  20. 4. Start Seafile server:
  21. # service seafile-server start
  22. ### Upgrading
  23. Please run the appropriate upgrade scripts in
  24. `/usr/share/seafile/seafile-server/upgrade` before using the new
  25. version.
  26. For more information, see
  27. https://download.seafile.com/published/seafile-manual/upgrade/upgrade.md.
  28. Note that since version 7.1, configuration files are stored in
  29. `/etc/seafile` instead of `/usr/share/seafile`.
  30. If you are upgrading from a version before 7.1:
  31. 1. Run the upgrade scripts in
  32. `/usr/share/seafile/seafile-server/upgrade` up to 7.1.
  33. 2. Move the `conf` and `ccnet` directories from `/usr/share/seafile` to
  34. `/etc/seafile`.
  35. 3. If you are using a custom Seafile data directory location and have
  36. set this in `ccnet/seafile.ini`:
  37. Starting with 7.1, the Seafile data directory location will be taken
  38. from `/etc/config/seafile-server`, and any setting in
  39. `ccnet/seafile.ini` will be ignored.
  40. It is strongly recommended to migrate the custom location setting to
  41. `/etc/config/seafile-server` and rename/remove the `seafile.ini`
  42. file.
  43. Note that the _data_dir_ option in /etc/config/seafile-server
  44. determines the *parent* path to the Seafile data directory (along
  45. with the Seahub data directory and the Seahub database, if you are
  46. using SQLite). The actual Seafile data directory must be named
  47. `seafile-data`.
  48. For example, if your Seafile data directory is
  49. `/srv/seafile/my-seafile-data`:
  50. 1. Rename the directory to `seafile-data`, so now the Seafile data
  51. directory is `/srv/seafile/seafile-data`.
  52. 2. Move the Seahub data directory (`seahub-data`) from
  53. `/usr/share/seafile` into `/srv/seafile`.
  54. 3. If you are using SQLite, move the Seahub database (`seahub.db`)
  55. from `/usr/share/seafile` into `/srv/seafile`.
  56. 4. Set the _data_dir_ option in `/etc/config/seafile-server` to the
  57. parent path, `/srv/seafile`.
  58. 5. Rename or delete `ccnet/seafile.ini`.
  59. 4. Review/update your Seahub settings. In previous versions of the
  60. Seahub OpenWrt package, some of Seahub's default settings (in
  61. `/usr/share/seafile/seafile-server/seahub/seahub/settings.py`) were
  62. modified from the defaults shipped by upstream.
  63. Starting with 7.1, Seahub's default settings are the same as
  64. [upstream][seahub_settings], with custom settings added to
  65. `/etc/seafile/conf/seahub_settings.py` during setup for new
  66. installations.
  67. To use the same custom settings in your upgraded installation, add
  68. these lines to `/etc/seafile/conf/seahub_settings.py`:
  69. # Custom settings for OpenWrt
  70. USE_I18N = False
  71. USER_PASSWORD_MIN_LENGTH = 8
  72. USER_STRONG_PASSWORD_REQUIRED = True
  73. [seahub_settings]: https://github.com/haiwen/seahub/blob/v7.1.2-server/seahub/settings.py
  74. 5. Continue running the upgrade scripts up to the new version.