Directory contains scripts which help newcomers understand how the BringAuto software and hardware platform works.
- Python (version >= 3.9)
- Protobuf (version == 3.20)
- BringAuto Etna docker compose environment prepared and running
- install requirements by
pip3 install -r ./requirements.txt
- it helps to observe messages sent by BringAuto Daemon
- it may need recompiled protobuf files with following commands:
git submodule update --init --recursive
protoc -I"$(pwd)/../autonomy-host-protocol/" --python_out=. "$(pwd)/../autonomy-host-protocol/CarStateProtocol.proto"
protoc -I"$(pwd)/../autonomy-host-protocol/" --python_out=. "$(pwd)/../autonomy-host-protocol/IndustrialPortalProtocol.proto"
- run the script by
python3 third_party_monitoring.py
-i
or--ip-address
-- ip address of the MQTT broker, default is 172.17.0.1-p
or--port
-- port of the MQTT broker, default is 8883--ca-certs
-- certificate authority, default is ./certs/ca-chain.pem--certfile
-- client certificate, default is ./certs/client.pem--keyfile
-- key to client certificate, default is ./certs/client.key
- initializes the fleet management database with stops and routes
- is a submodule so it needs to be initialized by:
git submodule update --init --recursive
- run the script by
python3 fleet-init/main.py -c init_config.ini -m maps -d
- creates a new
docker-compose.yml
with docker images replaced by desired images built from local repositories - the config file
docker_compose_for_testing.json
needs to be adjustedetna_path
: needs to point to the root directory of the etna repositoryname
: needs to match a service name from the original compose filereplace
: to build a docker image from your local repository, change the tag totrue
path
: path to the root of the coresponding project (dockerfiles are taken from this directory)force_rebuild
: forces the docker image of that component to be rebuilt
- run the script by
python3 create_docker_compose_for_testing.py
{
"etna_path": "..",
"components": [
{
"name": "name-of-component",
"replace": false,
"path": "../../path/to/project",
"force_rebuild": false
}
]
}
-c
or--config
-- path to config file, default is ./docker_compose_config.json-o
or--output
-- path to output directory for docker-compose.yml, default is ./