Initial commit
This commit is contained in:
25
.gitignore
vendored
Normal file
25
.gitignore
vendored
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
|
||||||
|
# Binaries for programs and plugins
|
||||||
|
*.exe
|
||||||
|
*.exe~
|
||||||
|
*.dll
|
||||||
|
*.so
|
||||||
|
*.dylib
|
||||||
|
bin/*
|
||||||
|
|
||||||
|
# Test binary, build with `go test -c`
|
||||||
|
*.test
|
||||||
|
|
||||||
|
# Output of the go coverage tool, specifically when used with LiteIDE
|
||||||
|
*.out
|
||||||
|
|
||||||
|
# Kubernetes Generated files - skip generated files, except for vendored files
|
||||||
|
|
||||||
|
!vendor/**/zz_generated.*
|
||||||
|
|
||||||
|
# editor and IDE paraphernalia
|
||||||
|
.idea
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
*~
|
||||||
|
__debug_bin
|
||||||
33
README.md
Normal file
33
README.md
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
# monitor
|
||||||
|
|
||||||
|
operator demo
|
||||||
|
|
||||||
|
* 测试环境
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 安装 KinD
|
||||||
|
sudo curl -Lo /usr/local/bin/kind https://kind.sigs.k8s.io/dl/v0.20.0/kind-linux-amd64 && sudo chmod +x /usr/local/bin/kind
|
||||||
|
|
||||||
|
docker network create kind -o com.docker.network.bridge.name=br-kind
|
||||||
|
# 部署镜像仓库
|
||||||
|
docker run --restart always --network kind --name registry --tmpfs /var/lib/registry -p 0.0.0.0:5000:5000 -d registry:2
|
||||||
|
# 创建带有本地镜像仓库的集群
|
||||||
|
kind create cluster --image kindest/node:v1.24.15 --config=- <<EOF
|
||||||
|
kind: Cluster
|
||||||
|
apiVersion: kind.x-k8s.io/v1alpha4
|
||||||
|
networking:
|
||||||
|
apiServerPort: 6443
|
||||||
|
podSubnet: 172.16.0.0/16
|
||||||
|
serviceSubnet: 172.19.0.0/16
|
||||||
|
nodes:
|
||||||
|
- role: control-plane
|
||||||
|
- role: worker
|
||||||
|
- role: worker
|
||||||
|
containerdConfigPatches:
|
||||||
|
- |-
|
||||||
|
[plugins."io.containerd.grpc.v1.cri".registry.mirrors."docker.io"]
|
||||||
|
endpoint = ["https://hub-mirror.c.163.com"]
|
||||||
|
[plugins."io.containerd.grpc.v1.cri".registry.mirrors."localhost:5000"]
|
||||||
|
endpoint = ["http://registry:5000"]
|
||||||
|
EOF
|
||||||
|
```
|
||||||
Reference in New Issue
Block a user