Some Faust ideas.
- Python 3
- Docker
- Run a local Kafka server with
docker-compose -f dev/kafka.yaml up
- With
docker ps
, find the Docker container ID of thewurstmeister/kafka
container and save to environment withexport KAFKA_CONTAINER_ID=<container ID>
.
Now we can do the following:
- Listen on a topic:
docker container exec ${KAFKA_CONTAINER_ID} kafka-console-consumer.sh --bootstrap-server :9092 --topic <Topic name>
- Open a clean Python3 environment and install requirements with
pip install -r requirements.txt
- Run the main app with
python -m src worker -l info