Instalasi
Persyaratan Sistem
Section titled “Persyaratan Sistem”Persyaratan Minimum
Section titled “Persyaratan Minimum”| Komponen | Persyaratan |
|---|---|
| OS | Linux, macOS, Windows |
| Rust | 1.95+ |
| Memori | 4 GB RAM |
| Disk | 2 GB ruang kosong |
Rekomendasi
Section titled “Rekomendasi”| Komponen | Persyaratan |
|---|---|
| Rust | 1.95+ (terbaru yang didukung) |
| Memori | 8 GB RAM |
| CPU | Prosesor multi-core |
Menginstal Rust
Section titled “Menginstal Rust”Jika Anda belum menginstal Rust:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | shAtur versi toolchain yang benar:
rustup default 1.95Tambahkan target WASM untuk build komponen:
rustup target add wasm32-wasip2Menginstal GTC CLI
Section titled “Menginstal GTC CLI”Instal router gtc terlebih dahulu, lalu biarkan gtc install menginstal tool pendamping Greentic. Jangan instal greentic-cli atau crate pendamping satu per satu untuk penggunaan normal; gtc install menjaga binary yang didelegasikan tetap selaras dengan router.
cargo install cargo-binstallcargo binstall gtcgtc installgtc doctorgit clone https://github.com/greenticai/greentic.gitcd greentic/greenticcargo build --release
# Tambahkan ke PATHexport PATH="$PATH:$(pwd)/target/release"gtc installgtc doctorDownload dari GitHub Releases:
# macOS (Apple Silicon)curl -LO https://github.com/greenticai/greentic/releases/latest/download/gtc-darwin-arm64.tar.gztar -xzf gtc-darwin-arm64.tar.gzsudo mv gtc /usr/local/bin/
# macOS (Intel)curl -LO https://github.com/greenticai/greentic/releases/latest/download/gtc-darwin-x64.tar.gz
# Linux (x86_64)curl -LO https://github.com/greenticai/greentic/releases/latest/download/gtc-linux-x64.tar.gz
# Windows# Download gtc-windows-x64.zip dari releasesVerifikasi Instalasi
Section titled “Verifikasi Instalasi”gtc --versiongtc doctorDependensi Opsional
Section titled “Dependensi Opsional”Redis (Penyimpanan Sesi)
Section titled “Redis (Penyimpanan Sesi)”Untuk persistensi sesi produksi:
docker run -d --name redis -p 6379:6379 redis:alpinebrew install redisredis-serverNgrok/Cloudflared (URL Publik)
Section titled “Ngrok/Cloudflared (URL Publik)”Untuk provider berbasis webhook (Telegram, Slack, dll.):
# Instalbrew install ngrok/ngrok/ngrok # macOS# atau download dari https://ngrok.com/download
# Konfigurasingrok config add-authtoken TOKEN_ANDA
# Jalankanngrok http 8080# Instalbrew install cloudflared # macOS# atau download dari https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/install-and-setup/
# Jalankancloudflared tunnel --url http://localhost:8080Tool Development
Section titled “Tool Development”Greentic Toolchain
Section titled “Greentic Toolchain”Instal atau perbarui binary Greentic yang didelegasikan dan digunakan oleh router gtc:
gtc installGunakan gtc install --dry-run untuk melihat rencana instalasi. Untuk lingkungan terkontrol, pin toolchain:
gtc install --release 1.0.15gtc install --manifest ./greentic-toolchain.jsonPembuatan Komponen
Section titled “Pembuatan Komponen”gtc install menginstal tool pendamping standar. Untuk pengembangan komponen mandiri, Anda juga dapat menginstal cargo-component:
cargo binstall cargo-componentLalu gunakan permukaan komponen yang didelegasikan:
gtc dev component --helpMemverifikasi Setup Anda
Section titled “Memverifikasi Setup Anda”Jalankan perintah berikut untuk memverifikasi semuanya berfungsi:
# Cek GTC CLIgtc --help
# Cek target Rust WASMrustup target list --installed | grep wasm32-wasip2
# Buat dan jalankan bundle tesgtc wizard --dry-runPemecahan Masalah
Section titled “Pemecahan Masalah”Masalah Umum
Section titled “Masalah Umum”Error: “wasm32-wasip2 target not found”
rustup target add wasm32-wasip2Error: “Permission denied”
# Di Linux/macOS, pastikan binary bisa dieksekusichmod +x /usr/local/bin/gtcLangkah Selanjutnya
Section titled “Langkah Selanjutnya”- Mulai Cepat - Buat digital worker pertama Anda
- Ikhtisar Arsitektur - Pahami platform