{"id":34970,"date":"2024-09-12T10:29:15","date_gmt":"2024-09-12T03:29:15","guid":{"rendered":"http:\/\/jupitek.maudemo.vip\/index.php\/2024\/09\/12\/configure-and-use-salt-ssh-to-manage-your-linodes\/"},"modified":"2024-09-12T10:29:15","modified_gmt":"2024-09-12T03:29:15","slug":"configure-and-use-salt-ssh-to-manage-your-linodes","status":"publish","type":"post","link":"https:\/\/jupitek.maudemo.vip\/index.php\/2024\/09\/12\/configure-and-use-salt-ssh-to-manage-your-linodes\/","title":{"rendered":"C\u1ea5u h\u00ecnh v\u00e0 s\u1eed d\u1ee5ng Salt SSH \u0111\u1ec3 qu\u1ea3n l\u00fd Linodes"},"content":{"rendered":"<h2 id=\"introduction-to-salt-ssh\">Gi\u1edbi thi\u1ec7u v\u1ec1 Salt SSH<a href=\"https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/#introduction-to-salt-ssh\"><\/a><\/h2>\n<p>Salt SSH cho ph\u00e9p b\u1ea1n th\u1ef1c thi c\u00e1c l\u1ec7nh ho\u1eb7c tr\u1ea1ng th\u00e1i Salt m\u00e0 kh\u00f4ng c\u1ea7n c\u00e0i \u0111\u1eb7t g\u00f3i salt-minion.<\/p>\n<p>Trong qu\u00e1 tr\u00ecnh th\u1ef1c thi, Salt SSH s\u1ebd sao ch\u00e9p c\u00e1c t\u1eadp tin c\u1ea7n thi\u1ebft v\u00e0o th\u01b0 m\u1ee5c h\u1ec7 th\u1ed1ng \u0111\u00edch&nbsp;<code>\/tmp<\/code>th\u00f4ng qua SSH, sau \u0111\u00f3 th\u1ef1c thi c\u00e1c l\u1ec7nh v\u00e0 cu\u1ed1i c\u00f9ng d\u1ecdn s\u1ea1ch c\u00e1c t\u1eadp tin t\u1ea1m th\u1eddi c\u1ee7a Salt.<\/p>\n<p>Xin l\u01b0u \u00fd: V\u00ec s\u1eed d\u1ee5ng SSH n\u00ean Salt SSH ch\u1eadm h\u01a1n Salt chu\u1ea9n v\u1edbi ZeroMQ.<\/p>\n<h2 id=\"before-you-begin\">Tr\u01b0\u1edbc khi b\u1ea1n b\u1eaft \u0111\u1ea7u<a href=\"https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/#before-you-begin\"><\/a><\/h2>\n<p>1.H\u01b0\u1edbng d\u1eabn n\u00e0y gi\u1ea3 \u0111\u1ecbnh r\u1eb1ng b\u1ea1n \u0111ang s\u1eed d\u1ee5ng h\u1ec7 th\u1ed1ng d\u1ef1a tr\u00ean rpm (CentOS, RedHat, Oracle Enterprise Linux).<\/p>\n<p>2.H\u00e3y \u0111\u1ea3m b\u1ea3o r\u1eb1ng b\u1ea1n \u0111\u00e3 c\u00e0i \u0111\u1eb7t c\u00e1c g\u00f3i&nbsp;<code>salt<\/code>v\u00e0&nbsp;<code>salt-ssh<\/code>tr\u00ean m\u00e1y ch\u1ee7 c\u1ee7a m\u00ecnh. Ki\u1ec3m tra xem c\u00e1c g\u00f3i n\u00e0y \u0111\u00e3 \u0111\u01b0\u1ee3c c\u00e0i \u0111\u1eb7t ch\u01b0a:<\/p>\n<pre class=\"wp-block-code\"><code>$rpm -q salt\n$rpm -q salt-ssh<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: \u0110\u1ec3 bi\u1ebft h\u01b0\u1edbng d\u1eabn chi ti\u1ebft v\u1ec1 c\u00e1ch thi\u1ebft l\u1eadp kho l\u01b0u tr\u1eef SaltStack, vui l\u00f2ng tham kh\u1ea3o&nbsp;<a href=\"https:\/\/www.linode.com\/docs\/guides\/getting-started-with-salt-basic-installation-and-setup\/\">H\u01b0\u1edbng d\u1eabn c\u00e0i \u0111\u1eb7t Salt Stack<\/a><\/p>\n<p>3.Minions c\u1ee7a b\u1ea1n ph\u1ea3i c\u00e0i \u0111\u1eb7t Python. N\u1ebfu kh\u00f4ng c\u00e0i \u0111\u1eb7t Python tr\u00ean minions, b\u1ea1n s\u1ebd ch\u1ec9 c\u00f3 th\u1ec3 ch\u1ea1y Salt SSH \u1edf ch\u1ebf \u0111\u1ed9 th\u00f4. \u1ede ch\u1ebf \u0111\u1ed9 th\u00f4, l\u1ec7nh shell th\u00f4 kh\u00f4ng th\u1ec3 s\u1eed d\u1ee5ng c\u00e1c m\u00f4-\u0111un th\u1ef1c thi ho\u1eb7c \u00e1p d\u1ee5ng tr\u1ea1ng th\u00e1i Salt. N\u1ebfu b\u1ea1n \u0111ang ch\u1ea1y phi\u00ean b\u1ea3n hi\u1ec7n \u0111\u1ea1i c\u1ee7a CentOS\/RedHat, b\u1ea1n \u0111\u00e3 c\u00e0i \u0111\u1eb7t Python tr\u00ean h\u1ec7 th\u1ed1ng c\u1ee7a m\u00ecnh<\/p>\n<p>4.B\u1ea1n ph\u1ea3i c\u00f3 \u00edt nh\u1ea5t m\u1ed9t m\u00e1y ch\u1ee7 ch\u00ednh v\u00e0 m\u1ed9t m\u00e1y kh\u00e1ch.<\/p>\n<h2 id=\"set-up-salt-roster-file\">Thi\u1ebft l\u1eadp t\u1ec7p danh s\u00e1ch Salt&nbsp;<a href=\"https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/#set-up-salt-roster-file\"><\/a><\/h2>\n<p>T\u1ec7p Roster ch\u1ee9a th\u00f4ng tin h\u1ec7 th\u1ed1ng m\u1ee5c ti\u00eau, chi ti\u1ebft k\u1ebft n\u1ed1i v\u00e0 th\u00f4ng tin x\u00e1c th\u1ef1c. V\u1ecb tr\u00ed m\u1eb7c \u0111\u1ecbnh cho t\u1ec7p Roster l\u00e0:&nbsp;<code>\/etc\/salt\/roster<\/code>.<\/p>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: T\u1ec7p danh s\u00e1ch \u0111\u01b0\u1ee3c c\u1ea5u h\u00ecnh tr\u00ean m\u00e1y ch\u1ee7 ch\u00ednh.<\/p>\n<p>1.M\u1edf&nbsp;<code>\/etc\/salt\/roster<\/code>b\u1eb1ng tr\u00ecnh so\u1ea1n th\u1ea3o. X\u00e1c \u0111\u1ecbnh h\u1ec7 th\u1ed1ng m\u00e1y kh\u00e1ch b\u1eb1ng c\u00e1ch th\u00eam c\u00e1c d\u00f2ng sau v\u00e0o t\u1ec7p:<\/p>\n<p>\u0110\u00e2y l\u00e0 m\u1ed9t v\u00ed d\u1ee5 v\u1ec1 \u0111\u1ecbnh ngh\u0129a m\u00e1y ch\u1ee7 t\u1ed1i thi\u1ec3u<\/p>\n<pre class=\"wp-block-code\"><code>linode1:\n     host: &lt;IPADDRESS OR HOSTNAME&gt;\n     user: &lt;username&gt;\n     passwd: &lt;password&gt;<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: T\u1ec7p Roster l\u01b0u tr\u1eef d\u1eef li\u1ec7u theo \u0111\u1ecbnh d\u1ea1ng YAML. Kh\u00f4ng th\u00eam kho\u1ea3ng tr\u1eafng kh\u00f4ng c\u1ea7n thi\u1ebft v\u00e0o t\u1ec7p c\u1ea5u h\u00ecnh.<\/p>\n<p>2.N\u1ebfu b\u1ea1n c\u00f3 kh\u00f3a c\u00f4ng khai \u0111\u01b0\u1ee3c l\u01b0u tr\u1eef tr\u00ean minion v\u00e0 kh\u00f3a ri\u00eang tr\u00ean h\u1ec7 th\u1ed1ng ch\u00ednh, b\u1ea1n c\u00f3 th\u1ec3 c\u1ea5u h\u00ecnh quy\u1ec1n truy c\u1eadp v\u00e0o minion b\u1eb1ng kh\u00f3a ri\u00eang. \u0110\u1ec3 x\u00e1c th\u1ef1c kh\u00f3a c\u00f4ng khai, h\u00e3y th\u00eam c\u00e1c d\u00f2ng sau v\u00e0o t\u1ec7p Roster:<\/p>\n<pre class=\"wp-block-code\"><code>#This is an example of minimal host definition using private key:\nlinode1:\n    host: &lt;IPADDRESS OR HOSTNAME&gt;\n    user: &lt;username&gt;\n    priv: \/&lt;username_home_folder&gt;\/.ssh\/id_rsa<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: S\u1eed d\u1ee5ng kh\u00f3a SSH l\u00e0 c\u00e1ch an to\u00e0n nh\u1ea5t \u0111\u1ec3 truy c\u1eadp v\u00e0o m\u00e1y ch\u1ee7 c\u1ee7a b\u1ea1n v\u00ec m\u1eadt kh\u1ea9u kh\u00f4ng \u0111\u01b0\u1ee3c l\u01b0u tr\u1eef d\u01b0\u1edbi d\u1ea1ng v\u0103n b\u1ea3n thu\u1ea7n t\u00fay.<\/p>\n<p>3.\u0110\u1ec3 thi\u1ebft l\u1eadp k\u1ebft n\u1ed1i v\u1edbi m\u1ed9t minion nh\u01b0 m\u1ed9t ng\u01b0\u1eddi d\u00f9ng th\u00f4ng th\u01b0\u1eddng, b\u1ea1n ph\u1ea3i c\u1ea5u h\u00ecnh m\u1ed9t v\u00e0i t\u1ec7p. Trong tr\u01b0\u1eddng h\u1ee3p n\u00e0y, Salt s\u1ebd t\u1eadn d\u1ee5ng c\u00e1c \u0111\u1eb7c quy\u1ec1n th\u00f4ng qua sudo. \u0110\u1ec3 s\u1eed d\u1ee5ng sudo, h\u00e3y thi\u1ebft l\u1eadp&nbsp;<code>sudo: True<\/code>trong&nbsp;<code>host definition<\/code>ph\u1ea7n c\u1ee7a t\u1ec7p Roster. Theo m\u1eb7c \u0111\u1ecbnh, sudo s\u1ebd ch\u1ec9 ho\u1ea1t \u0111\u1ed9ng khi ng\u01b0\u1eddi d\u00f9ng th\u1ef1c s\u1ef1 \u0111\u0103ng nh\u1eadp qua TTY. B\u1ea1n c\u00f3 th\u1ec3 kh\u1eafc ph\u1ee5c \u0111i\u1ec1u n\u00e0y theo hai c\u00e1ch:<\/p>\n<p>V\u00f4 hi\u1ec7u h\u00f3a ki\u1ec3m tra TTY b\u1eb1ng c\u00e1ch b\u00ecnh lu\u1eadn m\u1ed9t d\u00f2ng trong t\u1ec7p sudoers tr\u00ean minion c\u1ee7a b\u1ea1n:<\/p>\n<pre class=\"wp-block-code\"><code># Defaults requiretty<\/code><\/pre>\n<p>Bu\u1ed9c ph\u00e2n b\u1ed5 TTY b\u1eb1ng c\u00e1ch thi\u1ebft l\u1eadp&nbsp;<code>tty: True<\/code>t\u00f9y ch\u1ecdn trong t\u1ec7p Danh s\u00e1ch c\u1ee7a b\u1ea1n:<\/p>\n<pre class=\"wp-block-code\"><code>linode1:\n    host: &lt;IPADDRESS OR HOSTNAME&gt;\n    user: &lt;username&gt;\n    passwd: &lt;password&gt;\n    sudo: True\n    tty: True<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: Quy\u1ec1n s\u1eed d\u1ee5ng th\u00f4ng qua sudo ch\u1ec9 ho\u1ea1t \u0111\u1ed9ng n\u1ebfu t\u00f9y ch\u1ecdn NOPASSWD \u0111\u01b0\u1ee3c thi\u1ebft l\u1eadp cho ng\u01b0\u1eddi d\u00f9ng \u0111ang k\u1ebft n\u1ed1i v\u1edbi minion trong&nbsp;<code>\/etc\/sudoers<\/code>. B\u1ea1n c\u00f3 th\u1ec3 t\u00ecm th\u00eam th\u00f4ng tin v\u1ec1 t\u1ec7p Roster trong&nbsp;<a href=\"https:\/\/docs.saltproject.io\/en\/latest\/topics\/ssh\/roster.html#ssh-roster\" target=\"_blank\" rel=\"noreferrer noopener\">t\u00e0i li\u1ec7u t\u1ec7p Roster<\/a>&nbsp;.<\/p>\n<p>4.Ki\u1ec3m tra xem m\u00e1y ch\u1ee7 ch\u00ednh c\u00f3 quy\u1ec1n truy c\u1eadp v\u00e0o m\u00e1y kh\u00e1ch hay kh\u00f4ng b\u1eb1ng l\u1ec7nh&nbsp;<code>salt-ssh<\/code>:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master ~]# salt-ssh linode1 test.ping\n<\/code><\/pre>\n<p>\u0110\u1ea7u ra s\u1ebd l\u00e0:<\/p>\n<pre class=\"wp-block-code\"><code>linode1:\n    True<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: N\u1ebfu kh\u00f3a SSH kh\u00f4ng \u0111\u01b0\u1ee3c tri\u1ec3n khai, b\u1ea1n c\u00f3 th\u1ec3 nh\u1eadn \u0111\u01b0\u1ee3c th\u00f4ng&nbsp;<code>The host key needs to be accepted, to auto accept run salt-ssh with the -i flag:<\/code>b\u00e1o. Trong tr\u01b0\u1eddng h\u1ee3p n\u00e0y, ch\u1ec9 c\u1ea7n ch\u1ea1y&nbsp;<code>salt-ssh<\/code>v\u1edbi c\u1edd -i. Kh\u00f3a n\u00e0y s\u1ebd cho ph\u00e9p Salt t\u1ef1 \u0111\u1ed9ng ch\u1ea5p nh\u1eadn kh\u00f3a c\u00f4ng khai c\u1ee7a minion. \u0110i\u1ec1u n\u00e0y ch\u1ec9 ph\u1ea3i \u0111\u01b0\u1ee3c th\u1ef1c hi\u1ec7n m\u1ed9t l\u1ea7n, trong qu\u00e1 tr\u00ecnh trao \u0111\u1ed5i kh\u00f3a SSH ban \u0111\u1ea7u.<\/p>\n<h2 id=\"remote-command-execution-via-salt-ssh\">Th\u1ef1c hi\u1ec7n l\u1ec7nh t\u1eeb xa qua Salt SSH<a href=\"https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/#remote-command-execution-via-salt-ssh\"><\/a><\/h2>\n<p>1.B\u1ea1n c\u00f3 th\u1ec3 th\u1ef1c hi\u1ec7n b\u1ea5t k\u1ef3 l\u1ec7nh n\u00e0o tr\u00ean minion c\u1ee7a m\u00ecnh th\u00f4ng qua&nbsp;<code>cmd<\/code>m\u00f4-\u0111un th\u1ef1c thi:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master ~]# salt-ssh linode1 cmd.run \"du -sh \/root\"\n    linode1:\n        15M \/root<\/code><\/pre>\n<p>2.Salt SSH h\u1ed7 tr\u1ee3 bi\u1ec3u th\u1ee9c ch\u00ednh quy globbing v\u00e0 PCRE. V\u00ed d\u1ee5, n\u1ebfu b\u1ea1n mu\u1ed1n th\u1ef1c thi l\u1ec7nh tr\u00ean t\u1ea5t c\u1ea3 c\u00e1c minion c\u00f3 t\u00ean ch\u1ee9a \u201clinode\u201d:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master ~]# salt-ssh \"linode*\" cmd.run 'uname -r'\nlinode1:\n    3.10.0-229.1.2.el7.x86_64\nlinode2:\n    2.6.32-573.3.1.el6.x86_64<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: Salt SSH th\u1ef1c thi nhi\u1ec1u l\u1ec7nh \u0111\u1ed3ng th\u1eddi, m\u1eb7c \u0111\u1ecbnh t\u1ed1i \u0111a l\u00e0 25 k\u1ebft n\u1ed1i \u0111\u1ed3ng th\u1eddi.<\/p>\n<p>3.C\u00f3 th\u1ec3 s\u1eed d\u1ee5ng b\u1ea5t k\u1ef3 m\u00f4-\u0111un th\u1ef1c thi n\u00e0o v\u1edbi Salt SSH. V\u1edbi c\u00e1c m\u00f4-\u0111un th\u1ef1c thi, b\u1ea1n c\u00f3 th\u1ec3 c\u00e0i \u0111\u1eb7t c\u00e1c g\u00f3i, ki\u1ec3m so\u00e1t c\u00e1c d\u1ecbch v\u1ee5, thu th\u1eadp th\u00f4ng tin h\u1ec7 th\u1ed1ng v\u00e0 nhi\u1ec1u h\u01a1n n\u1eefa.<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master ~]# salt-ssh linode1 pkg.install iftop\nlinode1:\n    ----------\n    iftop:\n    ----------\n    new:\n        1.0-0.14.pre4.el7\n    old:\n\n&#91;root@master ~]# salt-ssh linode1 service.restart httpd\n    linode1:\n        True\n\n&#91;root@master ~]# salt-ssh linode1 disk.percent \/var\n    linode1:\n        22%<\/code><\/pre>\n<p class=\"has-background\" style=\"background-color:#74f78c33\">Ghi ch\u00fa: Danh s\u00e1ch \u0111\u1ea7y \u0111\u1ee7 c\u00e1c m\u00f4-\u0111un th\u1ef1c thi c\u00f3 s\u1eb5n t\u1ea1i&nbsp;<a href=\"https:\/\/docs.saltproject.io\/en\/latest\/ref\/modules\/all\/index.html\" target=\"_blank\" rel=\"noreferrer noopener\">T\u00e0i li\u1ec7u m\u00f4-\u0111un th\u1ef1c thi<\/a>&nbsp;.<\/p>\n<h2 id=\"install-salt-minion-remotely-via-salt-ssh\">C\u00e0i \u0111\u1eb7t Salt-Minion t\u1eeb xa qua Salt SSH<a href=\"https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/#install-salt-minion-remotely-via-salt-ssh\"><\/a><\/h2>\n<p>M\u1ed9t tr\u01b0\u1eddng h\u1ee3p s\u1eed d\u1ee5ng th\u00fa v\u1ecb c\u1ee7a Salt SSH l\u00e0 t\u1ef1 \u0111\u1ed9ng h\u00f3a qu\u00e1 tr\u00ecnh c\u00e0i \u0111\u1eb7t b\u1eb1ng&nbsp;<code>salt-minion<\/code>c\u00e1ch s\u1eed d\u1ee5ng tr\u1ea1ng th\u00e1i Salt \u0111\u01a1n gi\u1ea3n.<\/p>\n<p>1.T\u1ea1o th\u01b0 m\u1ee5c ch\u1ee9a tr\u1ea1ng th\u00e1i c\u1ee7a b\u1ea1n:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master ~]# mkdir \/srv\/salt\/install_salt_minion<\/code><\/pre>\n<p>2.M\u1edf&nbsp;<code>\/srv\/salt\/install_salt_minion\/init.sls<\/code>t\u1ec7p v\u00e0 khai b\u00e1o tr\u1ea1ng th\u00e1i c\u1ee7a b\u1ea1n:<\/p>\n<pre class=\"wp-block-code\"><code># This is a state which will install salt-minion on your hosts using Salt SSH\n# It will install the SaltStack repo, install salt-minion from that repo, enable and start the salt-minion service and\n# declare master in \/etc\/salt\/minion file\nsalt-minion:\n    # Install SaltStack repo for RHEL\/Centos systems\n    pkgrepo.managed:\n        - name: salt-latest\n        - humanname: SaltStack Latest Release Channel for RHEL\/Centos $releasever\n        - baseurl: https:\/\/repo.saltproject.io\/yum\/redhat\/$releasever\/$basearch\/latest\n        - gpgkey: https:\/\/repo.saltproject.io\/yum\/redhat\/$releasever\/$basearch\/latest\/SALTSTACK-GPG-KEY.pub\n        - gpgcheck: 1\n        - enabled: 1\n    # Install the salt-minion package and all its dependencies.\n    pkg:\n        - installed\n        # Require that SaltStack repo is set up before installing salt-minion.\n        - require:\n            - pkgrepo: salt-latest\n    # Start and enable the salt-minion daemon.\n    service:\n        - running\n        - enable: True\n        # Require that the salt-minion package is installed before starting daemon\n        - require:\n            - pkg: salt-minion\n        # Restart salt-minion daemon if \/etc\/salt\/minion file is changed\n        - watch:\n            - file: \/etc\/salt\/minion\n\n# Configure Salt master in conf file\n\/etc\/salt\/minion:\n    file.managed:\n        # File will contain only one line\n        - contents:\n            - master: &lt;IPADDRESS OR HOSTNAME&gt;<\/code><\/pre>\n<p>3.\u0110\u1ec3 \u00e1p d\u1ee5ng tr\u1ea1ng th\u00e1i n\u00e0y, h\u00e3y ch\u1ea1y l\u1ec7nh sau:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master salt]#  salt-ssh linode2 state.apply install_salt_minion\n<\/code><\/pre>\n<p>4.Ki\u1ec3m tra xem kh\u00f3a c\u1ee7a minion c\u00f3 \u0111ang ch\u1edd ch\u1ea5p nh\u1eadn hay kh\u00f4ng b\u1eb1ng c\u00e1ch s\u1eed d\u1ee5ng&nbsp;<code>salt-key<\/code>l\u1ec7nh:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master salt]# salt-key -l un\nUnaccepted Keys:\n    linode2<\/code><\/pre>\n<p>5.\u0110\u1ec3 ho\u00e0n t\u1ea5t c\u1ea5u h\u00ecnh minion, h\u00e3y ch\u1ea5p nh\u1eadn kh\u00f3a c\u00f4ng khai c\u1ee7a n\u00f3:<\/p>\n<pre class=\"wp-block-code\"><code>&#91;root@master salt]# salt-key -a linode2<\/code><\/pre>\n<p>Sau khi kh\u00f3a minion \u0111\u01b0\u1ee3c ch\u1ea5p nh\u1eadn, minion s\u1ebd \u0111\u01b0\u1ee3c c\u1ea5u h\u00ecnh \u0111\u1ea7y \u0111\u1ee7 v\u00e0 s\u1eb5n s\u00e0ng \u0111\u1ec3 th\u1ef1c hi\u1ec7n l\u1ec7nh.<\/p>\n<p>Ngu\u1ed3n: https:\/\/www.linode.com\/docs\/guides\/configure-and-use-salt-ssh\/<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Gi\u1edbi thi\u1ec7u v\u1ec1 Salt SSH Salt SSH cho ph\u00e9p b\u1ea1n th\u1ef1c thi c\u00e1c l\u1ec7nh ho\u1eb7c tr\u1ea1ng th\u00e1i Salt m\u00e0 kh\u00f4ng c\u1ea7n c\u00e0i \u0111\u1eb7t g\u00f3i salt-minion. Trong qu\u00e1 tr\u00ecnh th\u1ef1c thi, Salt SSH s\u1ebd sao ch\u00e9p c\u00e1c t\u1eadp tin c\u1ea7n thi\u1ebft v\u00e0o th\u01b0 m\u1ee5c h\u1ec7 th\u1ed1ng \u0111\u00edch&nbsp;\/tmpth\u00f4ng qua SSH, sau \u0111\u00f3 th\u1ef1c thi c\u00e1c l\u1ec7nh v\u00e0<\/p>\n","protected":false},"author":1,"featured_media":35991,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[124],"tags":[],"class_list":["post-34970","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-salt"],"_links":{"self":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/posts\/34970","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=34970"}],"version-history":[{"count":0,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/posts\/34970\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/media\/35991"}],"wp:attachment":[{"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/media?parent=34970"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/categories?post=34970"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jupitek.maudemo.vip\/index.php\/wp-json\/wp\/v2\/tags?post=34970"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}