Deploying KubeEdge with binary is used to test, never use this way in production environment.
Limitation
- Need super user rights (or root rights) to run.
Setup Cloud Side (KubeEdge Master Node)
Create CRDs
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/devices/devices_v1alpha2_device.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/devices/devices_v1alpha2_devicemodel.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/reliablesyncs/cluster_objectsync_v1alpha1.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/reliablesyncs/objectsync_v1alpha1.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/router/router_v1_ruleEndpoint.yaml
kubectl apply -f https://raw.githubusercontent.com/kubeedge/kubeedge/master/build/crds/router/router_v1_rule.yaml
Prepare config file
# cloudcore --minconfig > cloudcore.yaml
please refer to configuration for cloud for details.
Run
# cloudcore --config cloudcore.yaml
Run cloudcore -h to get help info and add options if needed.
Setup Edge Side (KubeEdge Worker Node)
Prepare config file
generate config file
# edgecore --minconfig > edgecore.yamlget token value at cloud side:
# kubectl get secret -nkubeedge tokensecret -o=jsonpath='{.data.tokendata}' | base64 -dupdate token value in edgecore config file:
# sed -i -e "s|token: .*|token: ${token}|g" edgecore.yaml
The token is what above step get.
please refer to configuration for edge for details.
Run
If you want to run cloudcore and edgecore at the same host, run following command first:
# export CHECK_EDGECORE_ENVIRONMENT="false"
Start edgecore:
# edgecore --config edgecore.yaml
Run edgecore -h to get help info and add options if needed.