Upgrade & Migration Guide
Learn how to safely apply future version updates to your SnapReels platform without overwriting your custom modifications, environment variables, or databases.
0
Pre-Upgrade Backup (Crucial)
Before proceeding with any file replacements, it is highly recommended to secure your existing data.
- Database Backup: Create a dump of your MongoDB database to ensure no user data is lost in case of a migration error.
- Environment Variables: Backup your
.envfile. This file contains all your secure API keys and database strings. Never overwrite this file during an upgrade. - Android Backup: Copy your
google-services.jsonand your release Keystore file (.jks).
1A
Web Update (GadoHost Users)
If you are hosting your app on GadoHost, the update process is incredibly simple and done entirely through your browser.
- Download the latest source zip from CodeCanyon.
- Go to your GadoHost File Manager and navigate to your application root directory.
- Upload the
code.zipfile. - Right click the uploaded
code.zipand select Extract. When the extraction policy prompt appears, make sure to select Replace Overlaps.
Select Replace Overlaps when extracting
- Once extracted, find and delete the
.nextfolder in your file manager (this clears the old build cache). - Go to your Node.js apps dashboard. Click Stop on your app, wait a few seconds, and then click Re-launch. Your app will automatically rebuild and start!
Click Re-launch to rebuild and apply the update
1B
Web Update (Traditional VPS Users)
If you manage your own VPS via SSH, follow these terminal commands to safely upgrade.
- Download the latest
code.zipand upload it to your VPS (e.g./var/www/snapreels). - Navigate to your project directory:
cd /var/www/snapreels
- Extract the zip file over your existing files. Ensure it replaces overlaps but do not delete your .env file!
unzip -o code.zip
- Delete the old build cache folder:
rm -rf .next
- Install any new dependencies and rebuild the application:
npm install npm run build
- Restart your background PM2 process:
pm2 restart snapreels
2
Android App Update
Updating your Android app involves merging the latest source code while preserving your custom string names, application IDs, and API configurations.
- Before opening the new Android project, keep a backup of your current
AppConfig.kt. - Open the newly downloaded Android folder in Android Studio.
- Restore your API Link and Security API Key inside
AppConfig.kt. - If you changed the package name (e.g.
com.yourname.app), you will need to re-apply the package rename refactoring in the new project. - Generate your new signed release APK/AAB utilizing the same keystore file (
.jks) you used initially. If you lose or change the keystore, Google Play will reject the update. - Upload the new AAB bundle to the Google Play Console as a new release track version.