両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン |
python:fabric [2023/04/01 13:00] – [Fabric 1.x から 2.x へ再実装された経緯] ともやん | python:fabric [2023/05/07 20:17] (現在) – [Fabric - シンプルな Pythonic リモート実行とデプロイメント] ともやん |
---|
is licensed under | is licensed under |
<a href="https://creativecommons.org/licenses/by/2.0/?ref=ccsearch&atype=html" style="margin-right: 5px;">CC BY 2.0</a> | <a href="https://creativecommons.org/licenses/by/2.0/?ref=ccsearch&atype=html" style="margin-right: 5px;">CC BY 2.0</a> |
<a href="https://creativecommons.org/licenses/by/2.0/?ref=ccsearch&atype=html" target="_blank" rel="noopener noreferrer" style="display: inline-block;white-space: none;margin-top: 2px;margin-left: 3px;height: 22px !important;"><img style="height: inherit;margin-right: 3px;display: inline-block;" src="https://search.creativecommons.org/static/img/cc_icon.svg?image_id=fa43397b-0df5-4945-8ef6-d23fbdd0a832" /><img style="height: inherit;margin-right: 3px;display: inline-block;" src="https://search.creativecommons.org/static/img/cc-by_icon.svg" /> | |
</a></span> | </a></span> |
</html>\\ | </html>\\ |
ファブリック(fabric) はファブリーズ(febreze) ではないイメージです🤤\\ | ファブリック(fabric) とファブリーズ(febreze) は関係ないです🤤\\ |
爽やかなお兄さんがファブ(fab)っていますけど...😅💦💦💦\\ | 爽やかなお兄さんがファブ(fab)っていますけど...🤔\\ |
| |
本家: [[https://www.fabfile.org/|Welcome to Fabric! — Fabric documentation]]\\ | 本家: [[https://www.fabfile.org|Welcome to Fabric! — Fabric documentation - fabfile.org]] [[gtr>https://www.fabfile.org|翻訳]]\\ |
ソースコード: [[git>fabric/fabric|fabric/fabric: Simple, Pythonic remote execution and deployment.]]\\ | ソースコード: [[git>fabric/fabric|fabric/fabric: Simple, Pythonic remote execution and deployment.]]\\ |
| 関連: [[https://www.pyinvoke.org|Welcome to Invoke! — Invoke documentation - pyinvoke.org]] [[gtr>https://www.pyinvoke.org|翻訳]]\\ |
| [[https://www.paramiko.org/|Welcome to Paramiko! — Paramiko documentation]] [[gtr>https://www.paramiko.org/|翻訳]]\\ |
| ドキュメント: [[https://docs.pyinvoke.org|Welcome to Invoke’s documentation! — Invoke documentation]] [[gtr>https://docs.pyinvoke.org|翻訳]]\\ |
| ソースコード: [[git>pyinvoke/invoke|pyinvoke/invoke: Pythonic task management & command execution.]]\\ |
| [[git>paramiko/paramiko|GitHub - paramiko/paramiko: The leading native Python SSHv2 protocol library.]]\\ |
| |
===== Linux ===== | ===== Linux ===== |
<WRAP prewrap 100% color_term> | <WRAP color_term> |
<WRAP color_connamd><code> | <WRAP color_connamd><html><pre> |
$ pip install fabric | <b class=GRN>$</b> <b class=HIY>pip</b> install fabric |
</code></WRAP> | </pre></html></WRAP> |
<WRAP color_result><code> | <WRAP color_result><html><pre> |
Collecting fabric | Collecting fabric |
Downloading fabric-2.6.0-py2.py3-none-any.whl (53 kB) | Downloading fabric-3.0.0-py3-none-any.whl (53 kB) |
|████████████████████████████████| 53 kB 706 kB/s | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>53.3/53.3 kB</b> <b class=RED>343.5 kB/s</b> eta <b class=CYN>0:00:00</b> |
Collecting pathlib2 | Collecting invoke>=2.0 |
Downloading pathlib2-2.3.6-py2.py3-none-any.whl (17 kB) | Downloading invoke-2.0.0-py3-none-any.whl (162 kB) |
Collecting invoke<2.0,>=1.3 | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>162.2/162.2 kB</b> <b class=RED>908.3 kB/s</b> eta <b class=CYN>0:00:00</b> |
Downloading invoke-1.6.0-py3-none-any.whl (212 kB) | |
|████████████████████████████████| 212 kB 2.0 MB/s | |
Collecting paramiko>=2.4 | Collecting paramiko>=2.4 |
Downloading paramiko-2.8.0-py2.py3-none-any.whl (206 kB) | Downloading paramiko-3.1.0-py3-none-any.whl (211 kB) |
|████████████████████████████████| 206 kB 5.2 MB/s | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>211.2/211.2 kB</b> <b class=RED>1.1 MB/s</b> eta <b class=CYN>0:00:00</b> |
Collecting cryptography>=2.5 | Collecting bcrypt>=3.2 |
Downloading cryptography-36.0.0-cp36-abi3-manylinux_2_24_x86_64.whl (3.6 MB) | Downloading bcrypt-4.0.1-cp36-abi3-manylinux_2_28_x86_64.whl (593 kB) |
|████████████████████████████████| 3.6 MB 2.9 MB/s | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>593.7/593.7 kB</b> <b class=RED>1.8 MB/s</b> eta <b class=CYN>0:00:00</b> |
Collecting bcrypt>=3.1.3 | Collecting cryptography>=3.3 |
Downloading bcrypt-3.2.0-cp36-abi3-manylinux2010_x86_64.whl (63 kB) | Downloading cryptography-40.0.1-cp36-abi3-manylinux_2_28_x86_64.whl (3.7 MB) |
|████████████████████████████████| 63 kB 1.2 MB/s | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>3.7/3.7 MB</b> <b class=RED>2.9 MB/s</b> eta <b class=CYN>0:00:00</b> |
Collecting pynacl>=1.0.1 | Collecting pynacl>=1.5 |
Downloading PyNaCl-1.4.0-cp35-abi3-manylinux1_x86_64.whl (961 kB) | Downloading PyNaCl-1.5.0-cp36-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl (856 kB) |
|████████████████████████████████| 961 kB 2.4 MB/s | <b class=PipBAR>━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━</b> <b class=GRN>856.7/856.7 kB</b> <b class=RED>511.0 kB/s</b> eta <b class=CYN>0:00:00</b> |
Requirement already satisfied: six in ./pyJupyterLab/lib/python3.10/site-packages (from pathlib2->fabric) (1.16.0) | Requirement already satisfied: cffi>=1.12 in ./pyJupyterLab/lib64/python3.11/site-packages (from cryptography>=3.3->paramiko>=2.4->fabric) (1.15.1) |
Requirement already satisfied: cffi>=1.1 in ./pyJupyterLab/lib/python3.10/site-packages (from bcrypt>=3.1.3->paramiko>=2.4->fabric) (1.15.0) | Requirement already satisfied: pycparser in ./pyJupyterLab/lib64/python3.11/site-packages (from cffi>=1.12->cryptography>=3.3->paramiko>=2.4->fabric) (2.21) |
Requirement already satisfied: pycparser in ./pyJupyterLab/lib/python3.10/site-packages (from cffi>=1.1->bcrypt>=3.1.3->paramiko>=2.4->fabric) (2.21) | Installing collected packages: invoke, bcrypt, pynacl, cryptography, paramiko, fabric |
Installing collected packages: pynacl, cryptography, bcrypt, pathlib2, paramiko, invoke, fabric | Successfully installed bcrypt-4.0.1 cryptography-40.0.1 fabric-3.0.0 invoke-2.0.0 paramiko-3.1.0 pynacl-1.5.0 |
Successfully installed bcrypt-3.2.0 cryptography-36.0.0 fabric-2.6.0 invoke-1.6.0 paramiko-2.8.0 pathlib2-2.3.6 pynacl-1.4.0 | </pre></html></WRAP> |
</code></WRAP> | </WRAP> |
| |
| <WRAP color_term> |
| <WRAP color_connamd><html><pre> |
| <b class=GRN>$</b> <b class=HIY>pip</b> show {fabric,invoke,paramiko} |
| </pre></html></WRAP> |
| <WRAP color_result_long><html><pre> |
| Name: fabric |
| Version: 3.0.0 |
| Summary: High level SSH command execution |
| Home-page: https://fabfile.org |
| Author: Jeff Forcier |
| Author-email: jeff@bitprophet.org |
| License: BSD |
| Location: /home/tomoyan/pyJupyterLab/lib64/python3.11/site-packages |
| Requires: invoke, paramiko |
| Required-by: |
| --- |
| Name: invoke |
| Version: 2.0.0 |
| Summary: Pythonic task execution |
| Home-page: https://pyinvoke.org |
| Author: Jeff Forcier |
| Author-email: jeff@bitprophet.org |
| License: BSD |
| Location: /home/tomoyan/pyJupyterLab/lib64/python3.11/site-packages |
| Requires: |
| Required-by: fabric |
| --- |
| Name: paramiko |
| Version: 3.1.0 |
| Summary: SSH2 protocol library |
| Home-page: https://paramiko.org |
| Author: Jeff Forcier |
| Author-email: jeff@bitprophet.org |
| License: LGPL |
| Location: /home/tomoyan/pyJupyterLab/lib64/python3.11/site-packages |
| Requires: bcrypt, cryptography, pynacl |
| Required-by: fabric |
| </pre></html></WRAP> |
</WRAP> | </WRAP> |
| |
===== Windows ===== | ===== Windows ===== |
<code> | <WRAP color_term> |
| <WRAP color_command><code> |
> pip install fabric | > pip install fabric |
</code> | </code></WRAP> |
<WRAP prewrap 100% #result_long> | <WRAP color_result><code> |
<code> | |
Collecting fabric | Collecting fabric |
Downloading fabric-2.6.0-py2.py3-none-any.whl (53 kB) | Downloading fabric-2.6.0-py2.py3-none-any.whl (53 kB) |
Installing collected packages: pycparser, six, cffi, pynacl, cryptography, bcrypt, pathlib2, paramiko, invoke, fabric | Installing collected packages: pycparser, six, cffi, pynacl, cryptography, bcrypt, pathlib2, paramiko, invoke, fabric |
Successfully installed bcrypt-3.2.0 cffi-1.14.5 cryptography-3.4.7 fabric-2.6.0 invoke-1.5.0 paramiko-2.7.2 pathlib2-2.3.5 pycparser-2.20 pynacl-1.4.0 six-1.16.0 | Successfully installed bcrypt-3.2.0 cffi-1.14.5 cryptography-3.4.7 fabric-2.6.0 invoke-1.5.0 paramiko-2.7.2 pathlib2-2.3.5 pycparser-2.20 pynacl-1.4.0 six-1.16.0 |
</code> | </code></WRAP> |
</WRAP> | </WRAP> |
| |
</style> | </style> |
</html> | </html> |
| |
| ==== fabric and fabric2 vs fabric3 ==== |
<note> | <note> |
**fabric and fabric2 vs fabric3**\\ | **fabric and fabric2 vs fabric3**\\ |
<wrap hi>//言い換えると、fabric2 は、1.x のユーザーが 2.0 の “主要な書き換え” の壁を越えるのを助けるためだけに存在します。将来のメジャー バージョンは大規模な書き換えではなく、下位互換性のない小さなセットのみが含まれます。//</wrap>\\ | <wrap hi>//言い換えると、fabric2 は、1.x のユーザーが 2.0 の “主要な書き換え” の壁を越えるのを助けるためだけに存在します。将来のメジャー バージョンは大規模な書き換えではなく、下位互換性のない小さなセットのみが含まれます。//</wrap>\\ |
\\ | \\ |
本家 [[https://www.fabfile.org/installing.html|Installing — Fabric documentation]] より\\ | 本家: [[https://www.fabfile.org/installing.html#fabric-and-fabric2-vs-fabric3|Installing#fabric and fabric2 vs fabric3 — Fabric documentation]] より\\ |
| GitHub: [[git>fabric/fabric/issues/1791|Clarify fabric vs fabric2 vs fabric3 differences · Issue #1791 · fabric/fabric]] ([[https://github-com.translate.goog/fabric/fabric/issues/1791?_x_tr_sl=zh-CN&_x_tr_tl=ja&_x_tr_hl=ja&_x_tr_pto=sc|翻訳]])\\ |
</note> | </note> |
| |
| ==== Upgrading from 1.x ==== |
<note> | <note> |
**Upgrading from 1.x**\\ | **Upgrading from 1.x**\\ |
</note> | </note> |
| |
| ==== Why was Invoke split off from the Fabric project? ==== |
[[https://www.pyinvoke.org/|Welcome to Invoke! — Invoke documentation]] より抜粋\\ | [[https://www.pyinvoke.org/|Welcome to Invoke! — Invoke documentation]] より抜粋\\ |
<note> | <note> |
[[https://www.pyinvoke.org/faq.html|Frequently asked questions — Invoke documentation]] より\\ | [[https://www.pyinvoke.org/faq.html|Frequently asked questions — Invoke documentation]] より\\ |
</note> | </note> |
| |
| ===== タスク定義 ===== |
| [[https://docs.fabfile.org/en/1.12.1/usage/tasks.html|Defining tasks — Fabric documentation]] ([[gtr>https://docs.fabfile.org/en/1.12.1/usage/tasks.html|翻訳]])\\ |
| |
===== 参考文献 ===== | ===== 参考文献 ===== |
[[https://fabric-ja.readthedocs.io/ja/latest/index.html|Fabricのドキュメントへようこそ ! — Fabric ドキュメント]] (1.10.1 日本語訳)\\ | [[https://fabric-ja.readthedocs.io/ja/latest/index.html|Fabricのドキュメントへようこそ ! — Fabric ドキュメント]] (1.10.1 日本語訳 古い)\\ |
[[qita>Esfahan/items/1e4bdf14b4a22263a1cf|fabric2のインストール手順と簡単な使い方 - Qiita]]\\ | [[https://fabric-ja.readthedocs.io/ja/latest/usage/interactivity.html|リモートプログラムとのやりとり — Fabric ドキュメント]]\\ |
| |
| ==== 付録 ==== |
| [[tw>tomoyan596sp/status/1642416698392449024|JupyterLab の Notebook で自動インストールを始めた🤤Python の Invoke Responder で、入力に自動応答できるけど英語文献しか出てこないようだ🤔Automatically responding to program output — Invoke documentation]]\\ |
| |