- Implement bidirectional KK-KTP linkage system (address-based & NIK-based) - Optimize scanner for mobile devices (touch slop, larger hit areas, modal locking) - Add NIK validation (16-digit numeric) with client-side feedback - Set default RT/RW values to '000' for both KK and KTP forms - Change 'Kpl Keluarga' label to 'Kepala Keluarga' - Improve scanner error messages and user feedback - Remove redundant 'Deteksi Dokumen' button - Add database schema updates and Docker support files
67 lines
1.6 KiB
Markdown
67 lines
1.6 KiB
Markdown
# SIDAK Docker Setup
|
|
|
|
Aplikasi SIDAK berjalan dengan Docker Compose.
|
|
|
|
## Services yang berjalan:
|
|
1. **Web App** - PHP Apache: http://localhost:8500
|
|
2. **Database** - MariaDB: localhost:3307
|
|
3. **phpMyAdmin** - Database admin: http://localhost:8080
|
|
|
|
## Cara menjalankan:
|
|
|
|
### 1. Start aplikasi:
|
|
```bash
|
|
docker compose up -d
|
|
```
|
|
|
|
### 2. Stop aplikasi:
|
|
```bash
|
|
docker compose down
|
|
```
|
|
|
|
### 3. Stop dan hapus data:
|
|
```bash
|
|
docker compose down -v
|
|
```
|
|
|
|
### 4. Melihat logs:
|
|
```bash
|
|
docker compose logs -f
|
|
```
|
|
|
|
## Credentials:
|
|
|
|
### Aplikasi SIDAK:
|
|
- URL: http://localhost:8500
|
|
- Admin: `admin` / `admin`
|
|
- Kaur: `kaur` / `kaur`
|
|
|
|
### Database:
|
|
- Host: `db` (dalam container) atau `localhost:3307` (dari host)
|
|
- Database: `data_penduduk`
|
|
- User: `sidak_user`
|
|
- Password: `sidak_pass`
|
|
- Root password: `rootpassword`
|
|
|
|
### phpMyAdmin:
|
|
- URL: http://localhost:8080
|
|
- Server: `db`
|
|
- Username: `sidak_user` atau `root`
|
|
- Password: `sidak_pass` atau `rootpassword`
|
|
|
|
## Troubleshooting:
|
|
|
|
1. **Port conflict**: Jika port 8500, 8080, atau 3307 sudah digunakan, ubah di `docker-compose.yml`
|
|
2. **Database connection error**: Tunggu 30 detik untuk database startup
|
|
3. **PHP extensions**: Extensions mysqli, pdo, pdo_mysql sudah diinstall otomatis
|
|
4. **File permissions**: Semua file di-mount dari host ke container
|
|
|
|
## Struktur file Docker:
|
|
- `docker-compose.yml` - Konfigurasi services
|
|
- `init.sql` - Skema dan data awal database
|
|
- `inc/koneksi.php` - Konfigurasi koneksi database (menggunakan env variables)
|
|
|
|
## Catatan:
|
|
- Perubahan file PHP langsung terlihat (hot reload)
|
|
- Data database persist di volume Docker `sidak_mariadb-data`
|
|
- Untuk development, edit file langsung di host |