To make the Carla Apollo Bridge work properly, you need to start the following three containers:
Apollo container
$ bash docker/scripts/dev_start.sh
$ bash docker/scripts/dev_into.sh
//in container
./apollo.sh build_gpu
./scripts/bootstrap.sh
The above commands start Apollo/CyberRT environment and Dreamview service, where CyberRT HOST(CYBER_IP) is the external address of the container. Since the container is started with HOST network, in Ubuntu, the CYBER_IP is 172.17.0.1(docker0)
Carla container
cd carla_apollo_bridge/scripts
./docker_run_carla.sh
The preceding command starts a Carla container with HOST network. You can access the Carla service through docker0(172.17.0.1).
Carla_Apollo_Bridge Container
cd carla_apollo_bridge/docker
./build_docker.sh
./run_docker.sh
docker exec -ti carla_cyber_0.9.14 bash
The preceding command starts Carla Apollo Bridge container. By default, the container uses the Docker Bridge Network and its external address is 172.17.0.X. The container uses the CyberRT environment, which is in the same Cyber Network as the Apollo container. They can discover and communicate with each other.
To sum up, its network architecture is as follows:
Other
Execution in Apollo container ./scripts/bootstrap.sh
will start the Dreamview service, Dreamview service is provided by CyberRT Node, this can be check with cyber_node list
in CyberRT environment (Apollo container or carla apollo bridge container)
Dreamview UI and Dreamview services communicate through Websocket.