摘要: Dockerfile文件内容 FROM centos RUN <命令行命令> # 多个命令之间用&&连接 COPY <源路径> <目标路径> # 从上下文目录中复制文件或目录到容器里制定路径 ADD <源路径> <目标路径> # 功能同ADD类似,官方推荐COPY CMD <命令行命令> # 类似 阅读全文
posted @ 2021-03-29 17:57 wanglai 阅读(195) 评论(0) 推荐(0) 编辑
摘要: 1.使用yaml文件创建Deployment kubectl create -f docs/user-guide/nginx-deployment.yaml --record # 创建成功后会输出:deployment "nginx-deployment" created 2.创建 # 通过命令行创 阅读全文
posted @ 2021-03-29 16:06 wanglai 阅读(564) 评论(0) 推荐(0) 编辑
摘要: ###获取pod的yaml格式 kubectl get pod podname -o yaml 自定义文件格式 apiVersion: v1 #必选,组名/版本号,kubectl api-version kind: Pod #必选 资源类型比如Deployment、Service 但是下面的内容要自 阅读全文
posted @ 2021-03-29 14:53 wanglai 阅读(1357) 评论(0) 推荐(0) 编辑
摘要: 安装rpm软件 1.安装软件:执行rpm -ivh rpm包名,如: #rpm -ivh apache-1.3.6.i386.rpm 2.升级软件:执行rpm -Uvh rpm包名。 3.反安装:执行rpm -e rpm包名。 4.查询软件包的详细信息:执行rpm -qpi rpm包名 5.查看某个 阅读全文
posted @ 2020-08-14 10:17 wanglai 阅读(2795) 评论(0) 推荐(0) 编辑
摘要: Freeswitch配置SIP网关拨打外部电话 为了实现freeswitch能够往外面(也就是打到你的手机号上)打电话,我们需要再freeswitch服务器上配置一些参数,当然前提是需要有一个SIP网关(硬件),一般是向网关服务商(华为,奥科等)购买,也可以直接向电信运营商购买。 1. 添加网关 添 阅读全文
posted @ 2020-08-14 10:03 wanglai 阅读(5798) 评论(0) 推荐(1) 编辑
摘要: 1. 查看mysql用户 select User,Host,authentication_string from mysql.user; + + + + | User | Host | authentication_string | + + + + | root | localhost | | | 阅读全文
posted @ 2020-07-18 09:24 wanglai 阅读(158) 评论(0) 推荐(0) 编辑
摘要: models.Batch.query.filter_by(batch=parent_folder, second=folder_name).first().searched=1 searched=1:需要更新的字段名称和值 阅读全文
posted @ 2020-07-01 15:07 wanglai 阅读(1097) 评论(0) 推荐(0) 编辑
摘要: 1. map 的用法: map()函数接收两个参数,一个是函数,一个是序列。 map将传入的函数依次作用到序列的每个元素,并把结果作为新的对象返回,返回值是一个可迭代对象,可以用list()方法将其转为一个列表。 def f(x): return x*x print(list(map(f, [1, 阅读全文
posted @ 2020-06-19 10:59 wanglai 阅读(198) 评论(0) 推荐(0) 编辑
摘要: 例子1:获取 Employee 表中第二高的薪水(Salary),没有第二高的则返回null select ifnull((select distinct Salary from Employee order by Salary desc limit 1, 1), null) as SecondHi 阅读全文
posted @ 2020-06-11 14:48 wanglai 阅读(174) 评论(0) 推荐(0) 编辑
摘要: pip install flask 安装 pip uninstall flask 卸载 pip list 查看当前环境下pip安装的库及版本 pip install flask-i https://mirrors.aliyun.com/pypi/simple # 使用国内源 pip -V # 查看p 阅读全文
posted @ 2020-06-02 14:52 wanglai 阅读(179) 评论(0) 推荐(0) 编辑