update to git
This commit is contained in:
+36
@@ -0,0 +1,36 @@
|
||||
# Analisa adaptasi log-viewer ke K3s
|
||||
|
||||
## Template
|
||||
|
||||
Struktur mengikuti `k3s-satusehat`: base Deployment/Service/probes/resources dan overlay Kustomize untuk environment, ingress, certificate, image tag, serta generated environment.
|
||||
|
||||
## Koreksi volume log
|
||||
|
||||
Source `docker-compose.yml` memakai bind mount host (`/mnt/simrs/logs:/app/logs`). Bind mount tersebut tidak boleh diterjemahkan secara literal menjadi `hostPath` di K3s karena log SIMRS sebenarnya berasal dari storage NFS aplikasi `simrs-v3`.
|
||||
|
||||
Deployment SIMRS menggunakan:
|
||||
|
||||
```yaml
|
||||
- name: vol-logs
|
||||
nfs:
|
||||
server: nas-rx300.rssa
|
||||
path: /export/simrs/logs
|
||||
readOnly: false
|
||||
```
|
||||
|
||||
Karena itu overlay production `log-viewer` memakai sumber NFS yang sama dan mount ke `/app/logs`. Overlay dev tidak menebak export NFS yang belum diketahui; sementara tetap menggunakan bind path dev yang ditemukan pada source aplikasi.
|
||||
|
||||
Konsekuensi:
|
||||
|
||||
- pod dapat berpindah worker tanpa kehilangan view log;
|
||||
- tidak membutuhkan `nodeSelector` khusus log;
|
||||
- tidak membutuhkan directory `/mnt/simrs/logs` pada filesystem worker;
|
||||
- semua worker yang dapat menjalankan pod harus mempunyai konektivitas dan dukungan NFS ke `nas-rx300.rssa`.
|
||||
|
||||
## Replica
|
||||
|
||||
Replica tetap satu. Shared NFS menghilangkan masalah node-local storage, tetapi tidak otomatis menjamin aplikasi aman terhadap concurrent mutation file. Scaling baru layak setelah operasi tulis/retention/unblock diuji untuk multi-process concurrency.
|
||||
|
||||
## Environment secret
|
||||
|
||||
Template sumber menaruh environment melalui ConfigMap. Pola itu dipertahankan agar konsisten, tetapi nilai credential sebaiknya dipisahkan ke Secret karena ConfigMap tidak dirancang sebagai penyimpanan secret.
|
||||
Reference in New Issue
Block a user