Follow these steps to move EspoCRM to another server:
Open a file manager or login via SSH to archive all available files from the EspoCRM directory. More details: https://www.espocrm.com/documentation/administration/backup-and-restore/#user-content-step-1-backup-files.
The data stored in database (MySQL, MariaDB) should be backed up. Please follow this recommendation: https://www.espocrm.com/documentation/administration/backup-and-restore/#user-content-step-2-backup-database.
Copy backups of files and of your database to a new server.
To unarchive backup files, you can use Archive Manager or this instruction: https://www.espocrm.com/documentation/administration/backup-and-restore/#user-content-step-1-unarchive-backup-files. Note: Files need to be placed in the web-server directory.
Configure a new server based on the recommendations here: https://www.espocrm.com/documentation/administration/server-configuration/.
Set required permissions and files owner, https://www.espocrm.com/documentation/administration/server-configuration/#user-content-required-permissions-for-unix-based-systems.
First, you have to create a new database with a user in MySQL. To import your database from the backup, follow these instructions: https://www.espocrm.com/documentation/administration/backup-and-restore/#user-content-step-3-import-database-dump.
After successfully importing and configuring the server, please correct EspoCRM configurations in the file
database connection settings:
'database' => [ 'driver' => 'pdo_mysql', 'dbname' => 'YOUR_DATABASE_NAME', 'user' => 'YOUR_USER', 'password' => 'YOUR_DATABASE_PASSWORD', 'host' => 'localhost', 'port' => '' ],
'siteUrl' => 'https://new-link.com',
'defaultPermissions' => [ 'user' => 'www-data', 'group' => 'www-data' ]
www-data is your web-server user.
Setup a crontab, https://www.espocrm.com/documentation/administration/server-configuration/#user-content-setup-a-crontab. Note: it should be configured under your web-server user.
That's all. Now, your EspoCRM instance is running on a new server.