{"id":613,"date":"2026-05-04T09:36:08","date_gmt":"2026-05-04T02:36:08","guid":{"rendered":"https:\/\/www.jakhoster.com\/blog\/cara-deploy-website-ke-vps\/"},"modified":"2026-05-23T13:29:47","modified_gmt":"2026-05-23T06:29:47","slug":"cara-deploy-website-ke-vps","status":"publish","type":"post","link":"https:\/\/www.jakhoster.com\/blog\/cara-deploy-website-ke-vps\/","title":{"rendered":"cara deploy website ke vps"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/www.jakhoster.com\/blog\/wp-content\/uploads\/2026\/05\/tmpeb9l4_tf.webp\" alt=\"cara deploy website ke vps\" \/><\/p>\n<p>Deploy website ke VPS (Virtual Private Server) menjadi pilihan banyak developer dan pemilik bisnis karena memberikan performa lebih stabil, fleksibilitas tinggi, dan kontrol penuh dibanding shared hosting. Dengan VPS, Anda dapat mengatur konfigurasi server sesuai kebutuhan website, baik untuk website company profile, toko online, aplikasi Laravel, WordPress, Node.js, hingga sistem billing.<\/p>\n<p>Bagi pemula, proses deploy website ke VPS mungkin terlihat rumit karena melibatkan SSH, konfigurasi web server, database, firewall, hingga DNS domain. Namun sebenarnya, jika dilakukan langkah demi langkah, proses ini cukup mudah dipahami.<\/p>\n<p>Artikel ini akan membahas secara lengkap cara deploy website ke VPS mulai dari persiapan server hingga website online dan aman digunakan.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Apa Itu VPS?<\/h2>\n<p>VPS atau Virtual Private Server adalah server virtual yang memiliki resource khusus seperti CPU, RAM, dan storage sendiri. Berbeda dengan shared hosting yang dipakai bersama banyak pengguna, VPS memberikan akses root sehingga Anda bebas menginstal software, mengubah konfigurasi, dan mengelola server sesuai kebutuhan.<\/p>\n<p>Keunggulan VPS:<\/p>\n<ul data-spread=\"false\">\n<li>Performa lebih stabil<\/li>\n<li>Resource dedicated<\/li>\n<li>Akses root penuh<\/li>\n<li>Bisa install software custom<\/li>\n<li>Cocok untuk traffic tinggi<\/li>\n<li>Lebih aman dibanding shared hosting<\/li>\n<li>Skalabilitas lebih fleksibel<\/li>\n<\/ul>\n<p>VPS biasanya digunakan untuk:<\/p>\n<ul data-spread=\"false\">\n<li>Hosting website WordPress<\/li>\n<li>Hosting Laravel<\/li>\n<li>Hosting Node.js<\/li>\n<li>Hosting Python\/Django<\/li>\n<li>Game server<\/li>\n<li>Mail server<\/li>\n<li>VPN server<\/li>\n<li>Sistem ERP dan billing<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Persiapan Sebelum Deploy Website<\/h1>\n<p>Sebelum mulai deploy website ke VPS, ada beberapa hal yang perlu dipersiapkan.<\/p>\n<h2>1. Memiliki VPS Aktif<\/h2>\n<p>Anda perlu menyewa VPS dari provider cloud atau hosting. Pastikan VPS memiliki:<\/p>\n<ul data-spread=\"false\">\n<li>Minimal RAM 1 GB<\/li>\n<li>Sistem operasi Ubuntu 22.04 atau Debian<\/li>\n<li>IP publik<\/li>\n<li>Akses root SSH<\/li>\n<\/ul>\n<p>Untuk website dengan traffic kecil hingga menengah, VPS 1\u20132 GB RAM sudah cukup.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>2. Domain Website<\/h2>\n<p>Siapkan domain yang akan diarahkan ke VPS.<\/p>\n<p>Contoh:<\/p>\n<ul data-spread=\"false\">\n<li>namadomain.com<\/li>\n<li><a>www.namadomain.com<\/a><\/li>\n<\/ul>\n<p>Nantinya domain diarahkan ke IP VPS menggunakan DNS.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>3. File Website<\/h2>\n<p>Siapkan source code website Anda.<\/p>\n<p>Bisa berupa:<\/p>\n<ul data-spread=\"false\">\n<li>HTML\/CSS\/JS<\/li>\n<li>WordPress<\/li>\n<li>Laravel<\/li>\n<li>Node.js<\/li>\n<li>PHP Native<\/li>\n<li>React build<\/li>\n<\/ul>\n<p>Upload dapat dilakukan menggunakan:<\/p>\n<ul data-spread=\"false\">\n<li>Git<\/li>\n<li>FTP\/SFTP<\/li>\n<li>SCP<\/li>\n<li>Rsync<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Langkah-Langkah Deploy Website ke VPS<\/h1>\n<h2>Langkah 1 \u2014 Login ke VPS via SSH<\/h2>\n<p>Di Linux atau macOS:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10g \u037c10h\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">ssh<\/span> root@IP-VPS<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Contoh:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10i \u037c10j\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">ssh<\/span> root@103.10.10.10<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jika menggunakan Windows, gunakan aplikasi:<\/p>\n<ul data-spread=\"false\">\n<li>PuTTY<\/li>\n<li>Windows Terminal<\/li>\n<li>MobaXterm<\/li>\n<\/ul>\n<p>Setelah login, masukkan password VPS.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 2 \u2014 Update Sistem VPS<\/h2>\n<p>Sebelum instalasi software, update package terlebih dahulu.<\/p>\n<p>Ubuntu\/Debian:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10k \u037c10l\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt update &amp;&amp; apt upgrade <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Update sistem penting untuk:<\/p>\n<ul data-spread=\"false\">\n<li>Keamanan server<\/li>\n<li>Patch bug<\/li>\n<li>Stabilitas software<\/li>\n<li>Kompatibilitas package<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 3 \u2014 Install Web Server<\/h2>\n<p>Web server paling umum:<\/p>\n<ul data-spread=\"false\">\n<li>Nginx<\/li>\n<li>Apache<\/li>\n<\/ul>\n<p>Pada tutorial ini kita menggunakan Nginx karena ringan dan cepat.<\/p>\n<p>Install Nginx:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10m \u037c10n\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install nginx <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Cek status:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10o \u037c10p\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">systemctl status nginx<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jika aktif, buka browser:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10q \u037c10r\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\">\n<div class=\"cm-line\">http:\/\/IP-VPS<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jika muncul halaman Welcome to Nginx berarti berhasil.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 4 \u2014 Install Database<\/h2>\n<p>Jika website menggunakan database, install MariaDB atau MySQL.<\/p>\n<p>Install MariaDB:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10s \u037c10t\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install mariadb-server <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Amankan database:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10u \u037c10v\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">mysql_secure_installation<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Ikuti proses:<\/p>\n<ul data-spread=\"false\">\n<li>Set password root<\/li>\n<li>Hapus anonymous user<\/li>\n<li>Disable remote root login<\/li>\n<li>Remove test database<\/li>\n<\/ul>\n<p>Login database:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10w \u037c10x\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">mysql <span class=\"\u037c1p\">-u<\/span> root <span class=\"\u037c1p\">-p<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 5 \u2014 Install PHP<\/h2>\n<p>Untuk website PHP seperti WordPress atau Laravel:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c10y \u037c10z\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install php php-fpm php-mysql php-cli php-curl php-xml php-mbstring php-zip unzip <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Cek versi PHP:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c110 \u037c111\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">php <span class=\"\u037c1p\">-v<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Cek PHP-FPM:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c112 \u037c113\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">systemctl status php8.3-fpm<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Sesuaikan versi PHP dengan repository server.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 6 \u2014 Upload File Website<\/h2>\n<p>Ada beberapa cara upload file.<\/p>\n<h2>Menggunakan Git<\/h2>\n<p>Install Git:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c114 \u037c115\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install <span class=\"\u037c1q\">git<\/span> <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Clone repository:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c116 \u037c117\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">git<\/span> clone https:\/\/github.com\/user\/project.git<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Menggunakan SCP<\/h2>\n<p>Dari komputer lokal:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c118 \u037c119\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">scp <span class=\"\u037c1p\">-r<\/span> project root@IP-VPS:\/var\/www\/<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Menggunakan SFTP<\/h2>\n<p>Gunakan aplikasi:<\/p>\n<ul data-spread=\"false\">\n<li>FileZilla<\/li>\n<li>WinSCP<\/li>\n<\/ul>\n<p>Port:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11a \u037c11b\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\">\n<div class=\"cm-line\">22<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Protocol:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11c \u037c11d\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\">\n<div class=\"cm-line\">SFTP<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 7 \u2014 Atur Permission File<\/h2>\n<p>Masuk ke folder website:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11e \u037c11f\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">cd<\/span> \/var\/www\/project<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Atur ownership:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11g \u037c11h\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">chown<\/span> <span class=\"\u037c1p\">-R<\/span> www-data:www-data \/var\/www\/project<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Atur permission:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11i \u037c11j\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">chmod<\/span> <span class=\"\u037c1p\">-R<\/span> <span class=\"\u037c1o\">755<\/span> \/var\/www\/project<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Permission penting agar website dapat diakses Nginx dan lebih aman.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 8 \u2014 Konfigurasi Nginx<\/h2>\n<p>Buat konfigurasi virtual host:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11k \u037c11l\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">nano \/etc\/nginx\/sites-available\/domain.com<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Isi konfigurasi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11m \u037c11n\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\">\n<div class=\"cm-line\">server {<\/div>\n<div class=\"cm-line\">listen 80;<\/div>\n<div class=\"cm-line\">server_name domain.com www.domain.com;<\/div>\n<div class=\"cm-line\"><\/div>\n<div class=\"cm-line\">root \/var\/www\/project\/public;<\/div>\n<div class=\"cm-line\">index index.php index.html;<\/div>\n<div class=\"cm-line\"><\/div>\n<div class=\"cm-line\">location \/ {<\/div>\n<div class=\"cm-line\">try_files $uri $uri\/ \/index.php?$query_string;<\/div>\n<div class=\"cm-line\">}<\/div>\n<div class=\"cm-line\"><\/div>\n<div class=\"cm-line\">location ~ \\.php$ {<\/div>\n<div class=\"cm-line\">include snippets\/fastcgi-php.conf;<\/div>\n<div class=\"cm-line\">fastcgi_pass unix:\/run\/php\/php8.3-fpm.sock;<\/div>\n<div class=\"cm-line\">}<\/div>\n<div class=\"cm-line\"><\/div>\n<div class=\"cm-line\">location ~ \/\\.ht {<\/div>\n<div class=\"cm-line\">deny all;<\/div>\n<div class=\"cm-line\">}<\/div>\n<div class=\"cm-line\">}<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Aktifkan konfigurasi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11o \u037c11p\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">ln<\/span> <span class=\"\u037c1p\">-s<\/span> \/etc\/nginx\/sites-available\/domain.com \/etc\/nginx\/sites-enabled\/<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Test konfigurasi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11q \u037c11r\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">nginx <span class=\"\u037c1p\">-t<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Restart Nginx:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11s \u037c11t\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">systemctl <span class=\"\u037c1q\">restart<\/span> nginx<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 9 \u2014 Arahkan Domain ke VPS<\/h2>\n<p>Masuk ke panel domain lalu ubah DNS.<\/p>\n<p>Tambahkan A Record:<\/p>\n<table>\n<tbody>\n<tr>\n<th>Type<\/th>\n<th>Name<\/th>\n<th>Value<\/th>\n<\/tr>\n<tr>\n<td>A<\/td>\n<td>@<\/td>\n<td>IP VPS<\/td>\n<\/tr>\n<tr>\n<td>A<\/td>\n<td>www<\/td>\n<td>IP VPS<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>Tunggu propagasi DNS sekitar 5\u201330 menit.<\/p>\n<p>Cek menggunakan:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11u \u037c11v\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">ping<\/span> domain.com<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jika mengarah ke IP VPS berarti berhasil.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Langkah 10 \u2014 Install SSL HTTPS<\/h2>\n<p>HTTPS sangat penting untuk:<\/p>\n<ul data-spread=\"false\">\n<li>Keamanan data<\/li>\n<li>SEO Google<\/li>\n<li>Kepercayaan pengunjung<\/li>\n<li>Mencegah warning browser<\/li>\n<\/ul>\n<p>Install Certbot:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11w \u037c11x\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install certbot python3-certbot-nginx <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Generate SSL:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c11y \u037c11z\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">certbot <span class=\"\u037c1p\">&#8211;nginx<\/span> <span class=\"\u037c1p\">-d<\/span> domain.com <span class=\"\u037c1p\">-d<\/span> www.domain.com<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Pilih redirect HTTP ke HTTPS.<\/p>\n<p>Cek SSL:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c120 \u037c121\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\">\n<div class=\"cm-line\">https:\/\/domain.com<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jika berhasil, website akan memiliki ikon gembok.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Deploy Laravel ke VPS<\/h1>\n<p>Jika menggunakan Laravel, ada tambahan langkah.<\/p>\n<h2>Install Composer<\/h2>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c122 \u037c123\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install composer <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Masuk ke project:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c124 \u037c125\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">cd<\/span> \/var\/www\/project<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Install dependency:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c126 \u037c127\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">composer install<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Copy environment:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c128 \u037c129\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">cp<\/span> .env.example .env<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Generate key:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12a \u037c12b\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">php artisan key:generate<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Migrasi database:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12c \u037c12d\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">php artisan migrate<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Optimasi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12e \u037c12f\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">php artisan optimize<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Set permission:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12g \u037c12h\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">chmod<\/span> <span class=\"\u037c1p\">-R<\/span> <span class=\"\u037c1o\">775<\/span> storage bootstrap\/cache<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Laravel siap dijalankan.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Deploy WordPress ke VPS<\/h1>\n<p>Untuk WordPress:<\/p>\n<h2>Download WordPress<\/h2>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12i \u037c12j\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">wget<\/span> https:\/\/wordpress.org\/latest.zip<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Extract:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12k \u037c12l\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">unzip latest.zip<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Pindahkan file:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12m \u037c12n\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">mv<\/span> wordpress\/* \/var\/www\/project\/<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Buat database:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12o \u037c12p\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"sql\">\n<div class=\"cm-line\"><span class=\"\u037c1m\">CREATE<\/span> DATABASE wordpress;<\/div>\n<div class=\"cm-line\"><span class=\"\u037c1m\">CREATE<\/span> <span class=\"\u037c1m\">USER<\/span> <span class=\"\u037c1n\">&#8216;wpuser&#8217;<\/span>@<span class=\"\u037c1n\">&#8216;localhost&#8217;<\/span> IDENTIFIED <span class=\"\u037c1m\">BY<\/span> <span class=\"\u037c1n\">&#8216;passwordku&#8217;<\/span>;<\/div>\n<div class=\"cm-line\"><span class=\"\u037c1m\">GRANT<\/span> <span class=\"\u037c1m\">ALL<\/span> <span class=\"\u037c1m\">PRIVILEGES<\/span> <span class=\"\u037c1m\">ON<\/span> wordpress.* <span class=\"\u037c1m\">TO<\/span> <span class=\"\u037c1n\">&#8216;wpuser&#8217;<\/span>@<span class=\"\u037c1n\">&#8216;localhost&#8217;<\/span>;<\/div>\n<div class=\"cm-line\">FLUSH <span class=\"\u037c1m\">PRIVILEGES<\/span>;<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Lanjutkan instalasi via browser.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Cara Deploy Website Node.js ke VPS<\/h1>\n<p>Install Node.js:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12q \u037c12r\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">apt install nodejs <span class=\"\u037c1q\">npm<\/span> <span class=\"\u037c1p\">-y<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Install PM2:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12s \u037c12t\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">npm<\/span> install pm2 <span class=\"\u037c1p\">-g<\/span><\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Jalankan aplikasi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12u \u037c12v\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">pm2 <span class=\"\u037c1q\">start<\/span> app.js<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Agar auto startup:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12w \u037c12x\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">pm2 startup<\/div>\n<div class=\"cm-line\">pm2 save<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Gunakan reverse proxy Nginx.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Tips Optimasi VPS Setelah Deploy<\/h1>\n<p>Setelah website online, lakukan optimasi berikut.<\/p>\n<h2>1. Aktifkan Firewall<\/h2>\n<p>Gunakan UFW:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c12y \u037c12z\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">ufw allow OpenSSH<\/div>\n<div class=\"cm-line\">ufw allow <span class=\"\u037c1n\">&#8216;Nginx Full&#8217;<\/span><\/div>\n<div class=\"cm-line\">ufw enable<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>2. Gunakan Swap<\/h2>\n<p>Untuk VPS RAM kecil:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c130 \u037c131\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">fallocate <span class=\"\u037c1p\">-l<\/span> 2G \/swapfile<\/div>\n<div class=\"cm-line\"><span class=\"\u037c1q\">chmod<\/span> <span class=\"\u037c1o\">600<\/span> \/swapfile<\/div>\n<div class=\"cm-line\">mkswap \/swapfile<\/div>\n<div class=\"cm-line\">swapon \/swapfile<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>3. Aktifkan Compression<\/h2>\n<p>Gunakan Brotli atau Gzip untuk mempercepat loading.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>4. Gunakan CDN<\/h2>\n<p>CDN membantu:<\/p>\n<ul data-spread=\"false\">\n<li>Mempercepat website<\/li>\n<li>Mengurangi beban server<\/li>\n<li>Proteksi DDoS<\/li>\n<\/ul>\n<p>Contoh:<\/p>\n<ul data-spread=\"false\">\n<li>Cloudflare<\/li>\n<li>BunnyCDN<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>5. Monitoring Server<\/h2>\n<p>Gunakan monitoring:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c132 \u037c133\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">htop<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<p>Atau:<\/p>\n<ul data-spread=\"false\">\n<li>Netdata<\/li>\n<li>Grafana<\/li>\n<li>Prometheus<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Kesalahan Umum Saat Deploy Website ke VPS<\/h1>\n<h2>Permission Denied<\/h2>\n<p>Biasanya karena ownership salah.<\/p>\n<p>Solusi:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c134 \u037c135\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\"><span class=\"\u037c1q\">chown<\/span> <span class=\"\u037c1p\">-R<\/span> www-data:www-data \/var\/www\/project<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>502 Bad Gateway<\/h2>\n<p>Biasanya PHP-FPM mati.<\/p>\n<p>Cek:<\/p>\n<div class=\"cm-editor \u037c1 \u037c2 \u037c4 \u037c136 \u037c137\" contenteditable=\"false\" data-is-code-block-view=\"true\">\n<div class=\"cm-announced\" aria-live=\"polite\"><\/div>\n<div class=\"cm-scroller\" tabindex=\"-1\">\n<div class=\"cm-content\" role=\"textbox\" contenteditable=\"true\" spellcheck=\"false\" translate=\"no\" aria-multiline=\"true\" data-language=\"shell\">\n<div class=\"cm-line\">systemctl status php8.3-fpm<\/div>\n<\/div>\n<div class=\"cm-layer cm-layer-above cm-cursorLayer\" aria-hidden=\"true\">\n<div class=\"cm-cursor cm-cursor-primary\"><\/div>\n<\/div>\n<div class=\"cm-layer cm-selectionLayer\" aria-hidden=\"true\"><\/div>\n<\/div>\n<\/div>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>Website Tidak Bisa Diakses<\/h2>\n<p>Penyebab:<\/p>\n<ul data-spread=\"false\">\n<li>Firewall<\/li>\n<li>DNS belum propagasi<\/li>\n<li>Nginx error<\/li>\n<li>Port tertutup<\/li>\n<\/ul>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h2>SSL Gagal<\/h2>\n<p>Pastikan domain sudah mengarah ke VPS sebelum generate SSL.<\/p>\n<div contenteditable=\"false\">\n<hr \/>\n<\/div>\n<h1>Kesimpulan<\/h1>\n<p>Deploy website ke VPS memang membutuhkan pemahaman dasar server Linux, namun memberikan banyak keuntungan dibanding shared hosting. Dengan VPS, Anda mendapatkan performa lebih tinggi, fleksibilitas konfigurasi, keamanan lebih baik, dan kemampuan scaling sesuai kebutuhan.<\/p>\n<p>Secara umum, proses deploy website ke VPS meliputi:<\/p>\n<ol start=\"1\" data-spread=\"false\">\n<li>Login SSH ke VPS<\/li>\n<li>Update sistem server<\/li>\n<li>Install web server<\/li>\n<li>Install database dan PHP<\/li>\n<li>Upload source code website<\/li>\n<li>Konfigurasi Nginx<\/li>\n<li>Hubungkan domain<\/li>\n<li>Install SSL HTTPS<\/li>\n<li>Optimasi keamanan dan performa<\/li>\n<\/ol>\n<p>Jika dilakukan dengan benar, website akan berjalan cepat, stabil, dan aman.<\/p>\n<p>Bagi developer maupun pemilik bisnis online, memahami cara deploy website ke VPS adalah skill penting karena memberi kontrol penuh terhadap infrastruktur hosting.<\/p>\n<p>Dengan mengikuti panduan di atas, Anda sudah dapat menjalankan website modern di VPS secara profesional.<\/p>\n<p><strong>Baca juga:<\/strong> <a href=\"https:\/\/www.jakhoster.com\/blog\/cara-memilih-hosting-terbaik\/\">Cara Memilih Hosting Terbaik untuk Website Anda<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Deploy website ke VPS (Virtual Private Server) menjadi pilihan banyak developer dan pemilik bisnis karena memberikan performa lebih stabil, fleksibilitas tinggi, dan kontrol penuh dibanding shared hosting. Dengan VPS, Anda dapat mengatur konfigurasi server sesuai kebutuhan website, baik untuk website company profile, toko online, aplikasi Laravel, WordPress, Node.js, hingga sistem billing. Bagi pemula, proses deploy [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":612,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-613","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-artikel"],"_links":{"self":[{"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/posts\/613","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/comments?post=613"}],"version-history":[{"count":1,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/posts\/613\/revisions"}],"predecessor-version":[{"id":1244,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/posts\/613\/revisions\/1244"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/media\/612"}],"wp:attachment":[{"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/media?parent=613"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/categories?post=613"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jakhoster.com\/blog\/wp-json\/wp\/v2\/tags?post=613"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}