Background:
I've setup up a standalone Pulsar locally and used Pulsar's python api docs to execute a simple consumer and producer modules.
Problem:
Transfer basic workflow into docker-compose.yaml
- Setup up standalone Pulsar locally.
- Install requirements.txt with needed for
consumer.pyandproducer.pymodules - Run
consumer.py - Run
producer.py
What I've done so far:
I've figured out how to compose the Pulsar standalone with the following yaml configuration
Current pulsar image:
version: '3.8'
services:
standalone:
image: apachepulsar/pulsar:2.8.1
ports:
- 8080:8080
- 6650:6650
command: bin/pulsar standalone
Where I'm lost
But I'm struggling conceptually with how I add Python 3.8 and the requirements need in the API docs to then be able to run the python commands python consumer.py and python producer.py