Nxdom Framework

Nusantara eXtreme Development Object Model — dokumentasi resmi

cloud_sync Remote Development — Live Deploy ke VPS

Fitur ini menyinkronkan file lokal ke VPS secara otomatis setiap kali ada perubahan. Tidak perlu upload manual.

1. Setup Server (pertama kali)

Klik kanan folder workspace di Discovery → Remote DevelopmentSetup Server

File konfigurasi <nama-folder>.deploy.json dibuat otomatis dan langsung dibuka di editor.

Isi field yang diperlukan:

{
  "protocol": "ssh",
  "host": "xxx.xxx.xxx.xxx",
  "user": "",
  "port": 22,
  "password": "password-server",
  "sshKey": "",
  "remotePath": "/home/public_html",
  "watchDebounce": 800,
  "watchIgnore": ".git,node_modules,.env,cache,*.log,.DS_Store,Thumbs.db"
}
FieldKeterangan
hostIP atau domain server
userUsername SSH
portPort SSH (default 22)
passwordPassword SSH — isi jika tidak pakai key
sshKeyPath private key SSH — isi jika pakai key, kosongkan jika pakai password
remotePathFolder tujuan di server (path absolut)
watchDebounceJeda (ms) sebelum deploy setelah file berubah
watchIgnoreFile/folder yang diabaikan, dipisah koma

Simpan file (Ctrl+S) setelah selesai mengisi.

2. Run Server

Klik kanan folder → Remote DevelopmentRun Server

  • Koneksi SSH diuji otomatis
  • Dot hijau muncul di sebelah nama folder → berhasil, file sync aktif
  • Dot merah muncul → gagal, periksa kembali konfigurasi

3. Stop Server

Klik kanan → Remote DevelopmentStop Server

Dot hilang, sinkronisasi berhenti.

4. Edit Config

Klik kanan → Remote DevelopmentEdit Config

Membuka kembali file .deploy.json untuk diedit.

5. Delete Config

Klik kanan → Remote DevelopmentDelete Config

Menghapus file config. Jika server sedang aktif, otomatis dihentikan dulu.


Indikator Badge

BadgeArti
Dot hijau berkedipServer aktif, koneksi OK, file sync berjalan
Dot merah berkedipKoneksi gagal saat Run Server diklik
Tidak ada badgeServer tidak aktif / belum dijalankan

Hover badge → tooltip menampilkan user@host:remotePath.


Cara Kerja Sinkronisasi

Jalur A — Simpan dari editor Discovery (Ctrl+S)
File langsung di-upload ke remote via SFTP.

Jalur B — Perubahan dari luar editor
File baru, file diedit dari terminal, AI agent, Windows Explorer, atau copy-paste — semua dipantau otomatis dan di-upload ke remote.

Yang tidak ter-sync:

  • File yang dihapus di lokal tidak ikut dihapus di remote
  • File di dalam daftar watchIgnore