Installation FAQ
How can I install Lychee without SSH access?
Section titled “How can I install Lychee without SSH access?”- Download the latest release
- Extract and upload the folder via FTP
- access the website
If you are at the wrong address you will be told to go to the public folder. Once open, you will be redirected to the install procedure. Completed you will be able to create an admin account and enjoy Lychee.
How do I upgrade from Lychee v3 to Lychee v4?
Section titled “How do I upgrade from Lychee v3 to Lychee v4?”The process is described here.
How can I back up my installation?
Section titled “How can I back up my installation?”To back up your Lychee installation you need to perform the following steps:
- Create a copy of at least the following parts of the Lychee directory tree (e.g.,
/var/www/html/Lychee):
.envpublic/dist/user.csspublic/uploads/- Dump the Lychee database to a file. E.g., if you are using MySQL, run:
mysqldump -u user -ppassword --databases lychee_database > lychee_backup.sqlReplace user, password, and lychee_database by the values of DB_USERNAME, DB_PASSWORD, and DB_DATABASE from the .env file in the Lychee folder.
How can I migrate my installation to a new host?
Section titled “How can I migrate my installation to a new host?”- Back up your installation as described above
- Download the latest release of Lychee.
- Overwrite the files with your back up
- Restore the database on the new host, e.g., for MySQL:
mysql -u user -ppassword < lychee_backup.sql
Can I host Lychee with a subpath with Nginx? Like https://example.dev/lychee/
Section titled “Can I host Lychee with a subpath with Nginx? Like https://example.dev/lychee/”Yes, here is a configuration to help you:
location ^~ /lychee { alias /var/www/lychee/public; index index.php; try_files $uri $uri/ @lychee; location ~ \.php$ { if (!-e $request_filename) { rewrite ^/lychee/?(.*)$ /lychee/index.php?/$1 last; break; } fastcgi_pass unix:/var/run/php/php7.4-fpm.sock; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $request_filename; }}location @lychee { rewrite /lychee/(.*)$ /lychee/index.php?/$1 last;}Can I host Lychee with a subpath with Apache? Like https://example.dev/lychee/
Section titled “Can I host Lychee with a subpath with Apache? Like https://example.dev/lychee/”Yes, the process is described here.
Do we really need writable app/?
Section titled “Do we really need writable app/?”From #311
Short answer: Lychee will work without a writable app/ folder.
The minimum set of directories that need to be http-writable is as follows:
storage/public/uploads/smallpublic/uploads/bigpublic/uploads/thumbpublic/uploads/mediumpublic/uploads/importpublic/distCan I migrate from a 64-bit system to a 32-bit system?
Section titled “Can I migrate from a 64-bit system to a 32-bit system?”Yes, but it’s not trivial or recommended. After copying the database:
- Download this file to your
database/migrations/folder. - Run the SQL command
delete from migrations where migration='2019_04_07_193345_fix_32bit';to make sure it will run. - Run
php artisan migrate. This should run a one-off migration that was originally added to allow 32-bit systems to migrate from Lychee v3.
This will only work on top-level albums. Subalbums will require manual intervention.
How can I stop artisan migrate and composer from running after every git pull?
Section titled “How can I stop artisan migrate and composer from running after every git pull?”We’ve set composer to install git pre-commit and post-merge hooks by default.
- The pre-commit is to help developers by checking and fixing and code style problems before they hit our testing. If you aren’t committing and changes, this will not be run.
- The post-merge ensures that your dependencies and database version are kept current. This can be disabled by creating a file
.NO_AUTO_COMPOSER_MIGRATEin your Lychee root and deleting (if necessary).git/hooks/post-merge. If you disable this script, you will need to runcomposerandartisan migratemanually.
