diff --git a/docs/deployment/pm2-nginx.md b/docs/deployment/pm2-nginx.md index 7820d23..89c6151 100644 --- a/docs/deployment/pm2-nginx.md +++ b/docs/deployment/pm2-nginx.md @@ -78,4 +78,16 @@ sudo ln -s /etc/nginx/sites-available/mernmail /etc/nginx/sites-enabled/mernmail ## 6. Restart NGINX -Restart NGINX using either `sudo systemctl restart nginx` or `sudo /etc/init.d/nginx restart` command. \ No newline at end of file +Restart NGINX using either `sudo systemctl restart nginx` or `sudo /etc/init.d/nginx restart` command. + +## Updating MERNMail + +To update the MERNMail webmail application, run these commands: + +```bash +cd ~/mernmail +git pull +npm run build +``` + +After updating MERNMail, restart MERNMail using the `pm2 restart "MERNMail"` command. \ No newline at end of file diff --git a/docs/deployment/svrjs.md b/docs/deployment/svrjs.md index efc509e..8014471 100644 --- a/docs/deployment/svrjs.md +++ b/docs/deployment/svrjs.md @@ -78,4 +78,14 @@ cp dist/mod.js /usr/lib/svrjs/mods/mernmail.js ## 6. Restart SVR.JS -Restart SVR.JS using either `sudo systemctl restart svrjs` or `sudo /etc/init.d/svrjs restart` command. \ No newline at end of file +Restart SVR.JS using either `sudo systemctl restart svrjs` or `sudo /etc/init.d/svrjs restart` command. + +## Updating MERNMail + +To update the MERNMail webmail application, run this command: + +```bash +sudo runuser svrjs -s /bin/bash -c 'cd /var/lib/mernmail && git pull && npm install && npm run build' +``` + +After updating MERNMail, restart SVR.JS using either `sudo systemctl restart svrjs` or `sudo /etc/init.d/svrjs restart` command. \ No newline at end of file