MindIO TFT provides services using SDKs and does not have resident processes. The services start when a training process starts, and exit when the training process finishes.
When MindCluster is adapted, MindCluster manages the Kubernetes container. The installation and adaptation process in the Kubernetes container is the same as that in a bare metal.
vim pod.yaml
ports:
- containerPort: 8000 # Communication port between the Controller and Processor of the MindIO TFT service
name: ttp-port
# Comment out the following two lines. The environment variable is configured by MindCluster.
# MASTER_ADDR=$(hostname -I | awk '{print $1}')
# MASTER_PORT=XXXX
# Obtain the MASTER_ADDR and MASTER_PORT environment variables (service network IP address of K8s) from Kubernetes.
CONTROLLER_ADDR=$(hostname -I | awk '{print $1}')
PROCESSOR_ADDR=${MASTER_ADDR}
export CONTROLLER_ADDR
export PROCESSOR_ADDR