Loading

摘要: k3s 私有仓库问题 现象 配置 /etc/rancher/k3s/registries.yaml 但是依旧无法使用私有镜像仓库(http) /var/lib/rancher/k3s/agent/etc/containerd/config.toml 也没有生成 私有镜像仓库配置 坑 在初始化 k3s 阅读全文
posted @ 2022-04-13 10:40 尚墨 阅读(1210) 评论(1) 推荐(0)
摘要: VSCode 设置选择补全快捷键位 tab 如果你是使用 Mac 电脑,那么 VSCode 的补全快捷键 control+n 选择下一个 control+p 选择上一个 个人认为你是一张白纸这个操作方式还是很不错的,但如果你是和我一样的老 Vim 按键习惯 tab 左下角齿轮 → 按键快捷方式 se 阅读全文
posted @ 2022-03-10 09:41 尚墨 阅读(3235) 评论(0) 推荐(0)
摘要: 命令行输入: defaults write -g ApplePressAndHoldEnabled -bool false 调整键盘配置 command + 空格 快速查找键盘配置 阅读全文
posted @ 2022-03-09 13:14 尚墨 阅读(203) 评论(0) 推荐(0)
摘要: iterm2 阅读全文
posted @ 2022-03-09 12:56 尚墨 阅读(226) 评论(0) 推荐(0)
摘要: 前言 我们在查看 Golang 代码的时候往往跳转到一个 interface{} 就终止了,这个时候你看不到代码的实现,其实这就是面向接口设计的一种巧妙之处,其实这里是为了让组合代替面向对象的复杂嵌套,或者说简化父子类形成的对象树。intreface{} 和 struct 的组合,interface 阅读全文
posted @ 2022-01-05 22:55 尚墨 阅读(328) 评论(0) 推荐(0)
摘要: gitlab适配性问题 构建 ssh-key ssh-keygen -t rsa -c "my.ad.name@gitlab.9527.com.cn" # 创建一个自定义名称的 ssh.key ssh-keygen -t rsa -c "my.ad.name@gitlab.9527.com.cn" 阅读全文
posted @ 2021-12-10 16:50 尚墨 阅读(78) 评论(0) 推荐(0)
摘要: gRPC环境搭建 Windows gRPC 环境搭建 1 下载 protoc 工具 下载地址:https://github.com/protocolbuffers/protobuf/releases/download/v3.19.1/protoc-3.19.1-win64.zip 获取解压完成后的目 阅读全文
posted @ 2021-12-10 14:11 尚墨 阅读(1458) 评论(0) 推荐(0)
摘要: http.Server{} 参数讲解 type Server struct { Addr string // 监听的TCP地址,如果为空字符串会使用":http" Handler Handler // 调用的处理器,如为nil会调用http.DefaultServeMux ReadTimeout t 阅读全文
posted @ 2021-11-25 10:03 尚墨 阅读(702) 评论(0) 推荐(0)
摘要: package main import "fmt" func main(){ var a int a = 100 var b int b = 2 per := float32(b/a) fmt.Printf("打印百分比: %.2f%%\n",per) truePer := float32(b)/f 阅读全文
posted @ 2021-11-25 09:59 尚墨 阅读(4014) 评论(0) 推荐(1)
摘要: # 添加一个仓库 helm repo add <REPO_URL> # 更新仓库信息 helm repo update # 安装一个 chart 包 helm install --namspace=nginxinc nginxinc nginx-stable/nginx-ingress # 查看一个 阅读全文
posted @ 2021-06-01 10:41 尚墨 阅读(155) 评论(0) 推荐(0)