add auto fetch ssl certs

This commit is contained in:
2021-08-26 12:11:25 +08:00
parent 11ca254bed
commit 509ac048fc
237 changed files with 4968 additions and 7406 deletions

View File

@@ -13,7 +13,7 @@
"articleSection" : "post",
"name" : "Transfer File Content Using Xclip in Terminal",
"headline" : "Transfer File Content Using Xclip in Terminal",
"description" : "\x3cp\x3e工作上常會需要用ssh登入遠端主機檢查LOG有必要的時候還要把log複製回本機來處理。\x3c\/p\x3e\n\n\x3cp\x3e以前都是傻傻的用 scp 傳檔案\x3c\/p\x3e\n\n\x3cp\x3e之前就記得有這個xclip\/xsel 可以用,但是一直沒有弄清楚怎麼執行\x3c\/p\x3e\n\n\x3cp\x3e早上研究了一下順便做個筆記。\x3c\/p\x3e",
"description" : "\x3cp\x3e工作上常會需要用ssh登入遠端主機檢查LOG有必要的時候還要把log複製回本機來處理。\x3c\/p\x3e\n\x3cp\x3e以前都是傻傻的用 scp 傳檔案\x3c\/p\x3e\n\x3cp\x3e之前就記得有這個xclip\/xsel 可以用,但是一直沒有弄清楚怎麼執行\x3c\/p\x3e\n\x3cp\x3e早上研究了一下順便做個筆記。\x3c\/p\x3e",
"inLanguage" : "en",
"author" : "Eric Chang",
"creator" : "Eric Chang",
@@ -45,9 +45,9 @@
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
<link href="https://h.cowbay.org/css/style.css?v=1626744134" rel="stylesheet" id="theme-stylesheet" type='text/css' media='all'>
<link href="https://h.cowbay.org/css/style.css?v=1629951055" rel="stylesheet" id="theme-stylesheet" type='text/css' media='all'>
<link href="https://h.cowbay.org/css/custom.css?v=1626744134" rel="stylesheet" type='text/css' media='all'>
<link href="https://h.cowbay.org/css/custom.css?v=1629951055" rel="stylesheet" type='text/css' media='all'>
<link rel="shortcut icon" href="https://h.cowbay.org/img/favicon.ico" type="image/x-icon">
<link rel="icon" href="https://h.cowbay.org/img/favicon.ico" type="image/x-icon">
@@ -81,10 +81,6 @@ if (!doNotTrack) {
<ul id="menu-secondary-items" class="menu-secondary-items">
<li class="menu-item menu-item-type-taxonomy menu-item-object-category">
<a href="/categories/"></a>
</li>
<li class="menu-item menu-item-type-taxonomy menu-item-object-category">
<a href="/categories/ansible">ansible</a>
</li>
@@ -309,22 +305,13 @@ if (!doNotTrack) {
<div class="entry-content">
<article>
<p>工作上常會需要用ssh登入遠端主機檢查LOG有必要的時候還要把log複製回本機來處理。</p>
<p>以前都是傻傻的用 scp 傳檔案</p>
<p>之前就記得有這個xclip/xsel 可以用,但是一直沒有弄清楚怎麼執行</p>
<p>早上研究了一下,順便做個筆記。</p>
<h3 id="1-ssh-要加上-x">1. ssh 要加上 -X</h3>
<h3 id="1-ssh-要加上--x-">1. ssh 要加上 -X</h3>
<p>不然會出現</p>
<pre><code>Error: Can't open display: (null)
</code></pre>
<p>這種錯誤訊息</p>
</code></pre><p>這種錯誤訊息</p>
<pre><code>-X Enables X11 forwarding. This can also be specified on a per-host basis in a configuration file.
X11 forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remote host (for the user's X
@@ -333,10 +320,7 @@ if (!doNotTrack) {
For this reason, X11 forwarding is subjected to X11 SECURITY extension restrictions by default. Please refer to the ssh -Y option and the
ForwardX11Trusted directive in ssh_config(5) for more information.
</code></pre>
<h3 id="2-remote-主機要安裝-xclip-xsel">2. remote 主機要安裝 xclip / xsel</h3>
</code></pre><h3 id="2-remote-主機要安裝-xclip--xsel-">2. remote 主機要安裝 xclip / xsel</h3>
<pre><code>2019-05-17 10:12:20 [minion@hqs019 ~]$ sudo apt install xsel
Reading package lists... Done
Building dependency tree
@@ -372,12 +356,8 @@ Preparing to unpack .../xclip_0.12+svn84-4build1_amd64.deb ...
Unpacking xclip (0.12+svn84-4build1) ...
Setting up xclip (0.12+svn84-4build1) ...
Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
</code></pre>
<h3 id="3-執行方式">3.執行方式</h3>
</code></pre><h3 id="3執行方式">3.執行方式</h3>
<p>執行以下指令,就可以把遠端的檔案內容傳送到「系統剪貼簿」,在本機就可以直接貼上了</p>
<pre><code>cat copy_neonexus.csv |xclip -selection clipboard
</code></pre>
</article>
@@ -654,7 +634,7 @@ title="pinterest icon"></i>
</ul> <div class="design-credit">
<p>&copy; 2018 Göran Svensson</p>
<p>© 2018 Göran Svensson</p>
<p>Nederburg Hugo Theme by <a href="https://appernetic.io">Appernetic</a>.</p>
@@ -666,7 +646,7 @@ title="pinterest icon"></i>
</div>
<script src="https://h.cowbay.org/js/jquery.min.js"></script>
<script src="https://h.cowbay.org/js/jquerymigrate.js"></script>
<script src="https://h.cowbay.org/js/production.min.js?v=1626744134"></script>
<script src="https://h.cowbay.org/js/production.min.js?v=1629951055"></script>
</body>
</html>