Skip to main content

VPS Update

This document will help you to update the Investra web frontend using VPS. This guide assumes you have already installed the web frontend on your VPS.

Step 1: Access VPS

You need to access your VPS. You can use SSH to access your VPS.

ssh username@ipaddress

Step 2: Upload the Web Files

  1. Extract the Investra package that you downloaded the latest version from CodeCanyon.
  2. On that folder, you'll get another file called core.zip.
  3. Now extract the core.zip file to the core folder.
  4. Now you'll get two zip files called admin.zip and standalone-client.zip on core folder.

Now upload the standalone-client.zip file to the server:

scp -r core/standalone-client.zip root@server:/var/www/investra/client

Step 3: Extract the Web Files

  1. Go to the client directory:
cd /var/www/investra/client
  1. Delete .next folder and extract the new files:
find . -mindepth 1 ! -name '.env' -exec rm -rf {} +

unzip -o standalone-client.zip -d /var/www/investra/client

rm -rf standalone-client.zip

Step 4: Restart the Web Application

  1. Build the project:
npm run build
  1. Delete the old PM2 process:
pm2 delete investra-client
  1. Start the project with PM2:
pm2 start npm --name "investra-client" -- run start
pm2 save

Now you have successfully updated your Investra web frontend on VPS.

Conclusion

Congratulations! You have successfully updated the web frontend on VPS.