Updating an existing VulaSocial node
Operator guide
Updating an existing VulaSocial node
Updating is additive and non-destructive when you follow this runbook. Always back up before you migrate.
Before you start — back up
# Database (MySQL)
mysqldump -u USER -p DATABASE > backups/node-$(date +%Y%m%d-%H%M).sql
# Or for SQLite
cp database/database.sqlite database/database.sqlite.bak-$(date +%Y%m%d-%H%M)
Also snapshot any user media if it's on local disk (storage/app/public).
1. Pull the new code
git pull
2. Update dependencies
composer install --no-dev --prefer-dist
If
composer.lockchanged, this installs exactly the versions it pins.
3. Run new migrations
php artisan migrate --force
Migrations are additive by policy — new tables/columns are created,
existing data is preserved. Never run migrate:fresh or db:wipe on a node
that has real members.
4. Refresh linked storage & caches
php artisan storage:link
php artisan optimize:clear
5. Restart workers
Shared hosting / cPanel:
# cron already calls queue:work --stop-when-empty, so it picks up new code automatically
VPS with systemd:
sudo systemctl restart vulasocial-queue
Docker:
docker compose up -d --build
6. Verify
- Homepage returns 200
- Login works
- The admin dashboard loads
- Check
storage/logs/laravel.logfor errors php artisan migrate:statusshows everything Ran (no Pending)
Update vs. upgrade
- Update = same major version, newer commit/tag — covered above.
- Upgrade = a new major version (e.g. framework bump). Check the release notes for breaking changes before migrating, and test on a copy first.
Roll back
If an update breaks something:
- Restore the code:
git checkout <previous-tag-or-commit>. - Restore dependencies:
composer install --no-dev --prefer-dist. - Restore the database from the backup taken in step "Before you start".
php artisan optimize:clear.
Data safety: never run destructive database commands on a live node. If you believe a migration will lose rows, stop and ask before proceeding.
Still stuck? Contact the node administrator.