摘要: 二进制安装 curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-darwin-amd64 sudo install minikube-darwin-amd64 /usr/local/bin/minikub 阅读全文
posted @ 2023-02-17 17:13 LiShiChao 阅读(97) 评论(0) 推荐(0) 编辑
摘要: >>> 0.15 * 3 0.44999999999999996 >>> from decimal import Decimal >>> Decimal('0.15') * 3 Decimal('0.45') 阅读全文
posted @ 2023-01-30 15:27 LiShiChao 阅读(21) 评论(0) 推荐(0) 编辑
摘要: # python一切皆对象class Foo(object): def __init__(self, name, version=None): self.name = name self.version = version def __setstate__(self, state): self.na 阅读全文
posted @ 2022-11-15 10:48 LiShiChao 阅读(49) 评论(0) 推荐(0) 编辑
摘要: 查看python的模块路径方法是 import sys print sys.path 这个就会打印出所有的模块路径。 下边是在这个python系统路径中加入新的模块路径的三种方法, 1、添加环境变量PYTHONPATH,python会添加此路径下的模块,在.bash_profile文件中添加如下类似 阅读全文
posted @ 2022-11-09 20:48 LiShiChao 阅读(4155) 评论(0) 推荐(1) 编辑
摘要: 编译安装redis # 下载源码包 ~]# wget http://download.redis.io/releases/redis-6.2.6.tar.gz ~]# tar -zxvf redis-6.2.6.tar.gz # 编译安装 ~]# cd redis-6.2.6 redis-6.2.6 阅读全文
posted @ 2022-11-01 13:42 LiShiChao 阅读(338) 评论(0) 推荐(0) 编辑
摘要: 安装依赖 yum install -y nginx-all-modules yum install -y nginx-mod-stream 阅读全文
posted @ 2022-10-31 10:05 LiShiChao 阅读(28) 评论(0) 推荐(0) 编辑
摘要: 常用配置 kind: Service apiVersion: v1 metadata: name: fastapiapp labels: app: fastapi spec: selector: app: fastapi ports: - protocol: TCP port: 80 targetP 阅读全文
posted @ 2022-10-30 11:35 LiShiChao 阅读(27) 评论(0) 推荐(0) 编辑
摘要: 环境准备 # 节点ip 172.25.131.227 k8s-master-01 # 设置主机名 ~]# hostnamectl set-hostname k8s-master-01 # 设置hosts解析 echo "172.25.131.227 k8s-master-01" >>/etc/hos 阅读全文
posted @ 2022-10-29 10:45 LiShiChao 阅读(413) 评论(0) 推荐(0) 编辑
摘要: yaml注解 apiVersion: v1 #指定api版本,此值必须在kubectl apiversion中 kind: Pod #指定创建资源的角色/类型 metadata: #资源的元数据/属性 name: test-pod #资源的名字,在同一个namespace中必须唯一 labels: 阅读全文
posted @ 2022-09-19 09:16 LiShiChao 阅读(84) 评论(0) 推荐(0) 编辑
摘要: yum安装 http://openresty.org/cn/linux-packages.html#centos # add the yum repo: wget https://openresty.org/package/centos/openresty.repo sudo mv openrest 阅读全文
posted @ 2022-06-21 17:14 LiShiChao 阅读(156) 评论(0) 推荐(0) 编辑