diff --git a/deploy/Dockerfile b/build/Dockerfile similarity index 100% rename from deploy/Dockerfile rename to build/Dockerfile diff --git a/deploy/redpanda/docker-compose.yaml b/deploy/redpanda/docker-compose.yaml new file mode 100644 index 0000000..82f90ae --- /dev/null +++ b/deploy/redpanda/docker-compose.yaml @@ -0,0 +1,81 @@ +version: "3.2" +# name: redpanda-quickstart +networks: + redpanda_network: + driver: bridge +volumes: + redpanda-0: null +services: + redpanda-0: + command: + - redpanda + - start + - --kafka-addr + - internal://0.0.0.0:9092,external://0.0.0.0:19092 + # use the internal addresses to connect to the Redpanda brokers' + # from inside the same Docker network. + # + # use the external addresses to connect to the Redpanda brokers' + # from outside the Docker network. + # + # address the broker advertises to clients that connect to the Kafka API. + - --advertise-kafka-addr + - internal://redpanda-0:9092,external://localhost:19092 + - --pandaproxy-addr + - internal://0.0.0.0:8082,external://0.0.0.0:18082 + # address the broker advertises to clients that connect to PandaProxy. + - --advertise-pandaproxy-addr + - internal://redpanda-0:8082,external://localhost:18082 + - --schema-registry-addr + - internal://0.0.0.0:8081,external://0.0.0.0:18081 + # Redpanda brokers use the RPC API to communicate with eachother internally. + - --rpc-addr + - redpanda-0:33145 + - --advertise-rpc-addr + - redpanda-0:33145 + # tells Seastar (the framework Redpanda uses under the hood) to use 1 core on the system. + - --smp 1 + # the amount of memory to make available to Redpanda. + - --memory 1G + # the amount of memory that's left for the Seastar subsystem. + # For development purposes this is set to 0. + - --reserve-memory 0M + # Redpanda won't assume it has all of the provisioned CPU + # (to accommodate Docker resource limitations). + - --overprovisioned + # enable logs for debugging. + - --default-log-level=debug + image: docker.redpanda.com/vectorized/redpanda:v22.3.11 + container_name: redpanda-0 + volumes: + - redpanda-0:/var/lib/redpanda/data + networks: + - redpanda_network + ports: + - 18081:18081 + - 18082:18082 + - 19092:19092 + - 19644:9644 + console: + container_name: redpanda-console + image: docker.redpanda.com/vectorized/console:v2.1.1 + networks: + - redpanda_network + entrypoint: /bin/sh + command: -c 'echo "$$CONSOLE_CONFIG_FILE" > /tmp/config.yml; /app/console' + environment: + CONFIG_FILEPATH: /tmp/config.yml + CONSOLE_CONFIG_FILE: | + kafka: + brokers: ["redpanda-0:9092"] + schemaRegistry: + enabled: true + urls: ["http://redpanda-0:8081"] + redpanda: + adminApi: + enabled: true + urls: ["http://redpanda-0:9644"] + ports: + - 8080:8080 + depends_on: + - redpanda-0 diff --git a/scripts/start.sh b/scripts/start.sh index 666d7f8..5beb329 100755 --- a/scripts/start.sh +++ b/scripts/start.sh @@ -1,8 +1,9 @@ #!/bin/sh export APP_PORT=9995 -export KAFKA_PORT=9092 +# export KAFKA_PORT=9092 +export KAFKA_PORT=19092 export KAFKA_HOST=127.0.0.1 -export KAFKA_HOST=37.143.12.169 +# export KAFKA_HOST=37.143.12.169 ./authDBService