Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
linux_wiki:python [2018/01/16 10:25] billdozor [Pip Config] |
linux_wiki:python [2019/05/25 23:50] (current) |
||
---|---|---|---|
Line 14: | Line 14: | ||
^ OS ^ System Package | ^ OS ^ System Package | ||
| CentOS 6.x | 2.6.6 | 3.4 | 2.7, 3.3, 3.4 | | | CentOS 6.x | 2.6.6 | 3.4 | 2.7, 3.3, 3.4 | | ||
- | | CentOS 7.x | 2.7 | 3.4 | 2.7, 3.3, 3.4, 3.5 | | + | | CentOS 7.x | 2.7 | 3.4, 3.6 |
* To avoid breaking system packages(ie yum uses python), let system packaged python versions stay maintained by the official repos. | * To avoid breaking system packages(ie yum uses python), let system packaged python versions stay maintained by the official repos. | ||
Line 23: | Line 23: | ||
====== Python3 Install: EPEL ====== | ====== Python3 Install: EPEL ====== | ||
- | To install python 3.4 from the EPEL< | + | To install python 3.4 from the EPEL |
+ | * 3.4<code bash>yum install python34</ | ||
+ | * 3.6<code bash>yum install python36</ | ||
---- | ---- | ||
Line 40: | Line 42: | ||
===== Install Pip ===== | ===== Install Pip ===== | ||
- | <code bash> | ||
- | wget https:// | ||
- | python get-pip.py | ||
- | </ | ||
+ | Install Pip into a Python environment | ||
+ | * Python2< | ||
+ | python get-pip.py</ | ||
+ | * Python3< | ||
+ | python3.6 get-pip.py</ | ||
+ | |||
+ | \\ | ||
+ | Install devel packages that many pip builds rely upon | ||
+ | * Python2< | ||
+ | * Python3.4< | ||
+ | * Python3.6< | ||
===== Pip Commands ===== | ===== Pip Commands ===== | ||
+ | |||
+ | **Python 2 vs Python 3 pip commands** | ||
+ | * **Python 2**<code bash>pip < | ||
+ | * **Python 3**<code bash> | ||
+ | |||
+ | \\ | ||
List installed python modules | List installed python modules | ||
<code bash> | <code bash> | ||
Line 51: | Line 66: | ||
</ | </ | ||
+ | \\ | ||
Show details about a Python module | Show details about a Python module | ||
<code bash> | <code bash> | ||
Line 56: | Line 72: | ||
</ | </ | ||
+ | \\ | ||
Search for a Python module | Search for a Python module | ||
<code bash> | <code bash> | ||
Line 61: | Line 78: | ||
</ | </ | ||
+ | \\ | ||
Install a Python module | Install a Python module | ||
<code bash> | <code bash> | ||
Line 66: | Line 84: | ||
</ | </ | ||
+ | \\ | ||
Upgrade a Python module | Upgrade a Python module | ||
<code bash> | <code bash> | ||
Line 71: | Line 90: | ||
</ | </ | ||
+ | \\ | ||
Upgrade pip | Upgrade pip | ||
<code bash> | <code bash> | ||
Line 76: | Line 96: | ||
</ | </ | ||
+ | \\ | ||
Uninstall | Uninstall | ||
<code bash> | <code bash> | ||
Line 87: | Line 108: | ||
There is a global config file and per user config file locations. | There is a global config file and per user config file locations. | ||
+ | \\ | ||
**Global pip config file** - example to format columns for all users< | **Global pip config file** - example to format columns for all users< | ||
[list] | [list] | ||
Line 98: | Line 120: | ||
#your config here</ | #your config here</ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ====== Python Modules ====== | ||
+ | |||
+ | Some commonly installed Python modules. | ||
+ | |||
+ | ===== Virtualenv ===== | ||
+ | |||
+ | Virtualenv "is a tool to create isolated Python environments." | ||
+ | |||
+ | Site: https:// | ||
+ | |||
+ | * Python2< | ||
+ | * Python3< | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== PipEnv ===== | ||
+ | |||
+ | PipEnv " | ||
+ | |||
+ | Site: https:// | ||
+ | |||
+ | * Python2< | ||
+ | * Python3< | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== AWS CLI ===== | ||
+ | |||
+ | AWS CLI "is a unified tool to manage your AWS services. With just one tool to download and configure, you can control multiple AWS services from the command line and automate them through scripts." | ||
+ | |||
+ | Site: https:// | ||
+ | |||
+ | Pre-Reqs< | ||
+ | |||
+ | Install | ||
+ | * Python2< | ||
+ | * Python3< | ||
+ | |||
+ | Verify | ||
+ | * Python2 and Python3< | ||
+ | |||
+ | ==== Cert Verify Failed ==== | ||
+ | |||
+ | If you are seeing errors while using the aws cli about "SSL: CERTIFICATE_VERIFY_FAILED" | ||
+ | * Point the aws cli to the system ca bundle (**per user**)< | ||
+ | |||
+ | # AWS CA Bundle | ||
+ | export AWS_CA_BUNDLE="/ | ||
+ | * Source the file< | ||
---- | ---- | ||