The AppGini Blog
A few tips and tricks to make your coding life a tiny bit better.

Moving an AppGini application to a new server

So, you have an AppGini-generated application that is up and running on your server. You then decided you want to move it to a new server. May be because you found a better hosting service, or you’re upgrading the server, or for any other reason. This is a simple checklist of the steps you should follow to make sure your app and data are moved successfully without any data losses, and with minimum downtime.

  1. On the old server you’re moving from, sign in to your AppGini app as admin, and go to the admin area.

  2. Open the Utilities menu > Database backups.

  3. Create a new backup.

  4. Go to the admin homepage by clicking the link to the top left of the page.

  5. Switch to maintenance mode. This would prevent users form modifying the database during migration.

    You might wish to edit the maintenance mode message displayed to users to tell them when the application is expected to be up again. To do so, open the Utilities menu > Admin settings, and scroll down to the “Maintenance mode message”, where you can edit the default message.

  6. Copy the entire application folder to your new server (to a folder under your web document root). Depending on your server configuration, this could be done using FTP, or SSH, or through the file manager under your server hosting control panel.

  7. On the new server, delete the config.php and setup.md5 files from the copied app folder. Also, under the ‘admin’ folder, delete the file ‘.maintenance’ (yes, it begins with a dot!)

  8. Open the URL of the application on your new server in a web browser. You should see the setup page.

  9. Enter your database login info and your admin user info (admin info should be the same as the old app: same admin username, password and email)

  10. After setup is finished, go to the admin area on the newly set-up app and open the Utilities menu > Database backups.

  11. You should see the backup file you made on your old server. Restore it to retrieve your data to the new server.

Following the above steps, your app should be ready on the new server, with all the data and uploaded files. Depending on your setup, you might also need to adjust your DNS settings to point your domain to the new server.