{"id":35088,"date":"2025-09-16T10:57:18","date_gmt":"2025-09-16T03:57:18","guid":{"rendered":"http:\/\/jupitek.maudemo.vip\/index.php\/2025\/09\/16\/deploy-a-lemp-stack-through-the-linode-marketplace\/"},"modified":"2025-09-16T10:57:18","modified_gmt":"2025-09-16T03:57:18","slug":"deploy-a-lemp-stack-through-the-linode-marketplace","status":"publish","type":"post","link":"https:\/\/jupitek.maudemo.vip\/index.php\/2025\/09\/16\/deploy-a-lemp-stack-through-the-linode-marketplace\/","title":{"rendered":"Deploy a LEMP Stack through the Linode Marketplace"},"content":{"rendered":"<p><!DOCTYPE html><br \/>\n<html lang=\"vi\"><br \/>\n<head><br \/>\n  <meta charset=\"UTF-8\"><br \/>\n  <title>Tri\u1ec3n khai LEMP Stack qua Linode Marketplace<\/title><\/p>\n<style>\n    * { box-sizing: border-box; }\n    html, body {\n      margin: 0;\n      padding: 0;\n      background: #ffffff;\n      color: #111827;\n      font: 16px\/1.7 system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, sans-serif;\n    }\n    header, nav, footer {\n      background: #ffffff;\n      border-bottom: 1px solid #e5e7eb;\n    }\n    header {\n      padding: 15px 30px;\n      display: flex;\n      align-items: center;\n      justify-content: space-between;\n    }\n    header nav a {\n      margin-left: 20px;\n      text-decoration: none;\n      color: #1f2937;\n      font-weight: 500;\n    }\n    main {\n      max-width: 900px;\n      margin: auto;\n      padding: 30px 20px;\n    }\n    h1, h2, h3 { color: #111827; }\n    pre {\n      background: #f9fafb;\n      padding: 12px;\n      border-radius: 6px;\n      overflow-x: auto;\n    }\n    code { background: #f3f4f6; padding: 2px 4px; border-radius: 4px; }\n    ul, ol { margin: 10px 0 10px 25px; }\n    blockquote {\n      border-left: 4px solid #3b82f6;\n      padding-left: 12px;\n      color: #555;\n      margin: 20px 0;\n    }\n    table {\n      border-collapse: collapse;\n      width: 100%;\n      margin: 20px 0;\n    }\n    th, td {\n      border: 1px solid #ddd;\n      padding: 10px;\n      text-align: left;\n    }\n    th { background: #f3f4f6; }\n    footer {\n      border-top: 1px solid #e5e7eb;\n      padding: 20px;\n      text-align: center;\n      font-size: 14px;\n      color: #6b7280;\n    }\n  <\/style>\n<p><\/head><br \/>\n<body><br \/>\n<main><\/p>\n<h1>Tri\u1ec3n khai LEMP Stack qua Linode Marketplace<\/h1>\n<p><strong>LEMP stack (Linux, NGINX, MySQL, PHP)<\/strong> l\u00e0 m\u1ed9t b\u1ed9 ph\u1ea7n m\u1ec1m m\u00e3 ngu\u1ed3n m\u1edf mi\u1ec5n ph\u00ed, d\u00f9ng \u0111\u1ec3 l\u01b0u tr\u1eef website tr\u00ean h\u1ec7 \u0111i\u1ec1u h\u00e0nh Linux. Kh\u00e1c v\u1edbi <em>LAMP Stack<\/em>, LEMP stack d\u00f9ng <strong>NGINX<\/strong> thay v\u00ec Apache. NGINX \u0111\u01b0\u1ee3c nhi\u1ec1u ng\u01b0\u1eddi d\u00f9ng \u01b0a chu\u1ed9ng nh\u1edd t\u00ednh linh ho\u1ea1t, t\u1ed1c \u0111\u1ed9 v\u00e0 hi\u1ec7u su\u1ea5t cao khi ch\u1ecbu t\u1ea3i l\u1edbn.<\/p>\n<h2>Tri\u1ec3n khai \u1ee9ng d\u1ee5ng Marketplace<\/h2>\n<ol>\n<li>\u0110\u0103ng nh\u1eadp Linode Cloud Manager \u2192 m\u1edf <strong>Marketplace<\/strong>.<\/li>\n<li>Ch\u1ecdn \u1ee9ng d\u1ee5ng <strong>LEMP Stack<\/strong>.<\/li>\n<li>\u0110i\u1ec1n form t\u1ea1o Linode (g\u00f3i, v\u00f9ng, SSH key\u2026) c\u00f9ng c\u00e1c t\u00f9y ch\u1ecdn ri\u00eang.<\/li>\n<li>Nh\u1ea5n <strong>Create Linode<\/strong>.<\/li>\n<li>Ch\u1edd c\u00e0i \u0111\u1eb7t ho\u00e0n t\u1ea5t v\u00e0 x\u00e1c minh.<\/li>\n<\/ol>\n<blockquote>\n<p><strong>L\u01b0u \u00fd:<\/strong> Th\u1eddi gian tri\u1ec3n khai \u01b0\u1edbc t\u00ednh: <strong>2\u20135 ph\u00fat<\/strong> sau khi m\u00e1y \u1ea3o \u0111\u00e3 provision xong.<\/p>\n<\/blockquote>\n<h2>T\u00f9y ch\u1ecdn c\u1ea5u h\u00ecnh<\/h2>\n<p><strong>H\u1ec7 \u0111i\u1ec1u h\u00e0nh h\u1ed7 tr\u1ee3:<\/strong> Ubuntu 24.04 LTS<br \/>\n     <strong>K\u1ebf ho\u1ea1ch \u0111\u1ec1 xu\u1ea5t t\u1ed1i thi\u1ec3u:<\/strong> 1GB Shared Compute Instance ho\u1eb7c cao h\u01a1n (tu\u1ef3 s\u1ed1 l\u01b0\u1ee3ng v\u00e0 k\u00edch th\u01b0\u1edbc site).<\/p>\n<h3>LEMP Stack Options<\/h3>\n<ul>\n<li><strong>Email address (b\u1eaft bu\u1ed9c):<\/strong> d\u00f9ng \u0111\u1ec3 t\u1ea1o ch\u1ee9ng ch\u1ec9 SSL.<\/li>\n<\/ul>\n<blockquote>\n<p>M\u1eadt kh\u1ea9u MySQL root \u0111\u01b0\u1ee3c t\u1ea1o t\u1ef1 \u0111\u1ed9ng v\u00e0 l\u01b0u t\u1ea1i: <code>\/home\/$USERNAME\/.credentials<\/code> khi c\u00e0i \u0111\u1eb7t ho\u00e0n t\u1ea5t.<\/p>\n<\/blockquote>\n<h3>Limited Sudo User<\/h3>\n<ul>\n<li><strong>Limited sudo user:<\/strong> nh\u1eadp t\u00ean user (kh\u00f4ng vi\u1ebft hoa, kh\u00f4ng kho\u1ea3ng tr\u1eafng ho\u1eb7c k\u00fd t\u1ef1 \u0111\u1eb7c bi\u1ec7t).<\/li>\n<li>M\u1eadt kh\u1ea9u cho user n\u00e0y c\u0169ng l\u01b0u trong <code>.credentials<\/code>.<\/li>\n<li>Th\u00eam SSH key \u2192 g\u00e1n cho root v\u00e0 limited user.<\/li>\n<li><strong>Disable root SSH:<\/strong> ch\u1ecdn C\u00f3 \u0111\u1ec3 ch\u1eb7n root \u0111\u0103ng nh\u1eadp tr\u1ef1c ti\u1ebfp qua SSH (ch\u1ec9 login qua Lish).<\/li>\n<\/ul>\n<h3>T\u00ean mi\u1ec1n t\u00f9y ch\u1ec9nh (Optional)<\/h3>\n<ul>\n<li><strong>Linode API Token:<\/strong> c\u1ea7n quy\u1ec1n Read\/Write Domains \u0111\u1ec3 t\u1ef1 \u0111\u1ed9ng t\u1ea1o b\u1ea3n ghi DNS.<\/li>\n<li><strong>Subdomain:<\/strong> v\u00ed d\u1ee5 <code>www<\/code> cho www.example.com.<\/li>\n<li><strong>Domain:<\/strong> v\u00ed d\u1ee5 <code>example.com<\/code>.<\/li>\n<\/ul>\n<p><strong>C\u1ea3nh b\u00e1o:<\/strong> Kh\u00f4ng d\u00f9ng d\u1ea5u ngo\u1eb7c k\u00e9p (<code>\"<\/code>) trong b\u1ea5t k\u1ef3 tr\u01b0\u1eddng c\u1ea5u h\u00ecnh n\u00e0o.<\/p>\n<h2>Sau khi tri\u1ec3n khai<\/h2>\n<ul>\n<li>\u0110\u0103ng nh\u1eadp v\u00e0o Linode qua SSH ho\u1eb7c Lish. Web root: <code>\/var\/www\/html<\/code>.<\/li>\n<li>Truy c\u1eadp domain \u0111\u00e3 khai b\u00e1o ho\u1eb7c rDNS c\u1ee7a Linode (v\u00ed d\u1ee5: <code>123-0-123-0.ip.linodeusercontent.com<\/code>).<\/li>\n<li>Upload file b\u1eb1ng SFTP (d\u00f9ng th\u00f4ng tin SSH root).<\/li>\n<li>C\u1ea5u h\u00ecnh DNS trong Linode DNS Manager ho\u1eb7c registrar c\u1ee7a b\u1ea1n.<\/li>\n<\/ul>\n<h3>T\u00e0i li\u1ec7u tham kh\u1ea3o<\/h3>\n<ul>\n<li>Secure HTTP Traffic with Certbot<\/li>\n<li>How to Configure NGINX<\/li>\n<li>How to Optimize MySQL Performance Using MySQLTuner<\/li>\n<\/ul>\n<h2>Ph\u1ea7n m\u1ec1m \u0111\u01b0\u1ee3c c\u00e0i s\u1eb5n<\/h2>\n<table>\n<tr>\n<th>Ph\u1ea7n m\u1ec1m<\/th>\n<th>M\u00f4 t\u1ea3<\/th>\n<\/tr>\n<tr>\n<td>NGINX<\/td>\n<td>Web server ph\u1ee5c v\u1ee5 site ho\u1eb7c \u1ee9ng d\u1ee5ng web<\/td>\n<\/tr>\n<tr>\n<td>MySQL Server<\/td>\n<td>C\u01a1 s\u1edf d\u1eef li\u1ec7u quan h\u1ec7<\/td>\n<\/tr>\n<tr>\n<td>PHP 7.4<\/td>\n<td>Ng\u00f4n ng\u1eef l\u1eadp tr\u00ecnh ph\u00eda server<\/td>\n<\/tr>\n<tr>\n<td>UFW<\/td>\n<td>T\u01b0\u1eddng l\u1eeda, m\u1edf port 22\/tcp v\u00e0 80\/tcp cho IPv4\/IPv6<\/td>\n<\/tr>\n<\/table>\n<h2>B\u1ea3o tr\u00ec<\/h2>\n<p>Akamai <strong>kh\u00f4ng qu\u1ea3n l\u00fd c\u1eadp nh\u1eadt<\/strong> ph\u1ea7n m\u1ec1m Marketplace. Ng\u01b0\u1eddi d\u00f9ng c\u1ea7n:<\/p>\n<ul>\n<li>C\u1eadp nh\u1eadt h\u1ec7 th\u1ed1ng \u0111\u1ecbnh k\u1ef3: <code>apt update && apt upgrade<\/code><\/li>\n<li>Theo d\u00f5i b\u1ea3n v\u00e1 b\u1ea3o m\u1eadt NGINX\/MySQL\/PHP<\/li>\n<li>Sao l\u01b0u d\u1eef li\u1ec7u th\u01b0\u1eddng xuy\u00ean<\/li>\n<\/ul>\n<h2>Tham kh\u1ea3o th\u00eam<\/h2>\n<ul>\n<li><a href=\"https:\/\/nginx.org\/en\/docs\/\" target=\"_blank\" rel=\"noopener\">NGINX Getting Started<\/a><\/li>\n<\/ul>\n<p><\/main><\/p>\n<footer>\n  \u00a9 2003-2025 Linode LLC. B\u1ea3n d\u1ecbch ti\u1ebfng Vi\u1ec7t.<br \/>\n<\/footer>\n<p><\/body><br \/>\n<\/html><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Tri\u1ec3n khai LEMP Stack qua Linode Marketplace Tri\u1ec3n khai LEMP Stack qua Linode Marketplace LEMP stack (Linux, NGINX, MySQL, PHP) l\u00e0 m\u1ed9t b\u1ed9 ph\u1ea7n m\u1ec1m m\u00e3 ngu\u1ed3n m\u1edf mi\u1ec5n ph\u00ed, d\u00f9ng \u0111\u1ec3 l\u01b0u tr\u1eef website tr\u00ean h\u1ec7 \u0111i\u1ec1u h\u00e0nh Linux. Kh\u00e1c v\u1edbi LAMP Stack, LEMP stack d\u00f9ng NGINX thay v\u00ec Apache. NGINX \u0111\u01b0\u1ee3c nhi\u1ec1u ng\u01b0\u1eddi<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[77],"tags":[],"class_list":["post-35088","post","type-post","status-publish","format-standard","hentry","category-guides-marketplace-doc"],"_links":{"self":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/posts\/35088","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/comments?post=35088"}],"version-history":[{"count":0,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/posts\/35088\/revisions"}],"wp:attachment":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/media?parent=35088"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/categories?post=35088"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/tags?post=35088"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}