# Release Checklist — Staging ke Production

Gunakan checklist ini setiap kali akan menaikkan update ke production.

## 1. Sebelum Deploy Staging

- [ ] Pull kode terbaru dari Git.
- [ ] Pastikan `.env` staging sudah benar.
- [ ] Jalankan `php scripts/preflight.php` di staging.
- [ ] Jalankan `php scripts/migrate.php status`.
- [ ] Jalankan `php scripts/migrate.php up` jika ada migration pending.

## 2. Test Staging

- [ ] Login berhasil.
- [ ] Dashboard tampil.
- [ ] Role user/kepala unit/admin dicek.
- [ ] Logbook & KPI tampil.
- [ ] Input logbook berhasil.
- [ ] Rekap staf/unit tampil.
- [ ] Jadwal jaga bisa upload/generate.
- [ ] Kegiatan harian bisa simpan dan rekap.
- [ ] Work order bisa simpan.
- [ ] Upload dokumen berhasil.
- [ ] Export Excel berhasil.
- [ ] Tidak ada error baru di `storage/logs/php-error.log`.

## 3. Sebelum Production

- [ ] Backup file production.
- [ ] Backup database production ke file `.sql`.
- [ ] Pastikan `.env` production tidak tertimpa.
- [ ] Pastikan folder `uploads/` production tidak tertimpa.
- [ ] Pastikan folder `storage/` production tetap writable.

## 4. Setelah Deploy Production

- [ ] Jalankan `php scripts/preflight.php`.
- [ ] Jalankan `php scripts/migrate.php status`.
- [ ] Jalankan `php scripts/migrate.php up` jika ada migration baru.
- [ ] Test login.
- [ ] Test 3 modul paling penting.
- [ ] Cek `storage/logs/php-error.log`.
