- Navigate to the folder containing the scripts
cd lora_kube
- Create cluster
kind create cluster --config config.yaml
- Check the status of kind cluster
kubectl cluster-info --context kind-kind
Check out cluster info if needed
kind get clusters
kind get nodes
kind get kubeconfig
- Create the deployment with the following command
kubectl apply -f deployment.yaml
Check out nodes/pods info
kubectl get deploy
kubectl get nodes
kubectl get pods
kubectl get all
kubectl describe deployments
kubectl exec pod-name -- curl 10.244.2.3
kubectl exec -ti lora-5f696f676f-6mwvh /bin/bash
curl https://172.18.0.2:31796 -k
kind load docker-image eabsics/5g-dive:radiohead --name kind
kind load docker-image eabsics/5g-dive:edge --name kind
- some useful command lines
a. watch the logs from a container
kubectl logs your-pod-here --follow
for(( ; ; )); do kubectl logs --tail=1 your-pod-herej; sleep 1; done
for((i=1;i<=1000;i+=1)); do kubectl logs --tail=1 pod/lora-deployment-edge-6bc89d56b8-snqcj; sleep 1; done
网友评论