摘要: The Zen of Python, by Tim Peters Beautiful is better than ugly.Explicit is better than implicit.Simple is better than complex.Complex is better than c 阅读全文
posted @ 2019-04-30 18:12 六月骄阳 阅读(289) 评论(0) 推荐(0) 编辑
摘要: CentOS7 默认使用的是firewall作为防火墙 查看防火墙状态 firewall-cmd --state 停止firewall systemctl stop firewalld.service 开启firewall firewall-cmd --state 禁止firewall 开机启动 s 阅读全文
posted @ 2019-04-30 17:10 六月骄阳 阅读(23823) 评论(0) 推荐(1) 编辑
摘要: 新建一个apps文件夹 需要整理的app文件夹拖到同一个文件夹中,即apps。(弹出对话框,取消勾选Search for references) 在pycharm中,右键apps文件夹--选择mark directory as --选择sources root. 工程的setting.py代码中添加 阅读全文
posted @ 2019-03-13 19:44 六月骄阳 阅读(944) 评论(0) 推荐(0) 编辑
摘要: 问题: >>> import MySQLdb Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/anaconda3/envs/LearnDjango/lib/python2.7/site-pac 阅读全文
posted @ 2018-09-07 22:54 六月骄阳 阅读(4773) 评论(0) 推荐(0) 编辑
摘要: CentOS7下安装docker: 通过命令uname -r 查看linux内核版本,版本低的话不支持docker。 [tim@num root]$ uname -r 3.10.0-514.el7.x86_64 1、安装和启动docker 1.1 更新yum源 1.2 安装docker,并查看doc 阅读全文
posted @ 2018-05-28 16:02 六月骄阳 阅读(204) 评论(0) 推荐(0) 编辑
摘要: 在学习docker之前,先了解一下什么是docker,以及docker技术存在的意义。 Docker是PaaS供应商dotCloud开源的一个基于LXC 的高级容器引擎,源代码托管在 GitHub 上, 基于Go语言开发并遵从Apache 2.0协议开源。Docker提供了一种在安全、可重复的环境中 阅读全文
posted @ 2018-05-27 18:51 六月骄阳 阅读(288) 评论(0) 推荐(0) 编辑
摘要: 在项目迭代的过程中,不可避免需要”上线“。上线对应着部署,或者重新部署;部署对应着修改;修改则意味着风险。 目前有很多用于部署的技术,有的简单,有的复杂;有的得停机,有的不需要停机即可完成部署。本文的目的就是将目前常用的布署方案做一个总结。 一、蓝绿布署 Blue/Green Deployment( 阅读全文
posted @ 2018-05-26 09:32 六月骄阳 阅读(468) 评论(0) 推荐(0) 编辑
摘要: 最简单的方式: pypiserver – minimal pypi server, easy to install & use 1、安装pypiserver:pip install pypiserver 2、新建文件夹用来存放离线包:mkdir ~/packages 3、启动服务:pypi-serv 阅读全文
posted @ 2018-05-26 00:33 六月骄阳 阅读(704) 评论(0) 推荐(0) 编辑
摘要: I do a lot of development without an internet connection1, so being able to install packages into a virtual environment without a connection to PyPI i 阅读全文
posted @ 2018-05-25 16:44 六月骄阳 阅读(6925) 评论(0) 推荐(0) 编辑
摘要: 用yum安装pip 1、输入yum install python-pip 如果提示 ,没有可用软件包 python-pip 2、输入yum -y install epel-release 这个软件包会自动配置yum的软件仓库 3、再次执行yum install python-pip 输入pip -V 阅读全文
posted @ 2018-05-25 12:25 六月骄阳 阅读(1177) 评论(0) 推荐(0) 编辑