Refactor Docker Compose configuration for warehouse services

- Updated the `docker-compose.yml` file to change the environment file path for services to use `.env` instead of `../.env`.
- Commented out the `postgres` service configuration to disable it temporarily.
- Updated the `rest` service to use the `ghcr.io/projectnessie/nessie` image, changed the container name to `nessie`, and modified the port mapping from `8181` to `19120`.
- Adjusted environment variables for the `rest` service to align with the new Nessie configuration.

These changes streamline the setup for the warehouse services and prepare for the integration of Nessie.
This commit is contained in:
dal 2025-01-06 15:17:04 -07:00
parent c77018abbd
commit b30801542d
1 changed files with 59 additions and 41 deletions

View File

@ -1,10 +1,8 @@
version: "3"
services: services:
starrocks-fe: starrocks-fe:
image: starrocks/fe-ubuntu:3.3-latest image: starrocks/fe-ubuntu:3.3-latest
env_file: env_file:
- ../.env - .env
hostname: starrocks-fe hostname: starrocks-fe
container_name: starrocks-fe container_name: starrocks-fe
user: root user: root
@ -60,52 +58,72 @@ services:
networks: networks:
iceberg_net: iceberg_net:
postgres: # postgres:
image: postgres:15 # image: postgres:15
container_name: postgres # container_name: postgres
networks: # networks:
iceberg_net: # iceberg_net:
aliases: # aliases:
- postgres # - postgres
ports: # ports:
- 5432:5432 # - 5432:5432
environment: # environment:
- POSTGRES_USER=postgres # - POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres # - POSTGRES_PASSWORD=postgres
- POSTGRES_DB=postgres # - POSTGRES_DB=postgres
volumes: # volumes:
- postgres_data:/var/lib/postgresql/data # - postgres_data:/var/lib/postgresql/data
healthcheck: # healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"] # test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 5s # interval: 5s
timeout: 5s # timeout: 5s
retries: 5 # retries: 5
rest: rest:
image: tabulario/iceberg-rest:latest image: ghcr.io/projectnessie/nessie
container_name: nessie
env_file: env_file:
- ../.env - .env
container_name: iceberg-rest
networks: networks:
iceberg_net: iceberg_net:
aliases: aliases:
- iceberg-rest - nessie
ports: ports:
- 8181:8181 - 19120:19120
environment: environment:
- AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID} - NESSIE_CATALOG_VALIDATE_SECRETS=true
- AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY} - NESSIE_CATALOG_DEFAULT_WAREHOUSE=warehouse
- AWS_REGION=${AWS_REGION} - NESSIE_CATALOG_WAREHOUSES_WAREHOUSE_LOCATION=${CATALOG_WAREHOUSE}
- AWS_DEFAULT_REGION=${AWS_REGION} - NESSIE_CATALOG_SERVICE_S3_DEFAULT_OPTIONS_REGION=${AWS_REGION}
- CATALOG_WAREHOUSE=${CATALOG_WAREHOUSE} - NESSIE_CATALOG_SERVICE_S3_DEFAULT_OPTIONS_ACCESS_KEY=urn:nessie-secret:quarkus:buster-nessie
- CATALOG_IO__IMPL=org.apache.iceberg.aws.s3.S3FileIO - BUSTER_NESSIE_DEFAULT_NAME=${AWS_ACCESS_KEY_ID}
- CATALOG_URI=jdbc:postgresql://postgres:5432/postgres - BUSTER_NESSIE_DEFAULT_SECRET=${AWS_SECRET_ACCESS_KEY}
- CATALOG_JDBC_USER=postgres
- CATALOG_JDBC_PASSWORD=postgres # rest:
- CATALOG_JDBC_INITIALIZE=true # image: tabulario/iceberg-rest:latest
depends_on: # env_file:
postgres: # - ../.env
condition: service_healthy # container_name: iceberg-rest
# networks:
# iceberg_net:
# aliases:
# - iceberg-rest
# ports:
# - 8181:8181
# environment:
# - AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID}
# - AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY}
# - AWS_REGION=${AWS_REGION}
# - AWS_DEFAULT_REGION=${AWS_REGION}
# - CATALOG_WAREHOUSE=${CATALOG_WAREHOUSE}
# - CATALOG_IO__IMPL=org.apache.iceberg.aws.s3.S3FileIO
# - CATALOG_URI=jdbc:postgresql://postgres:5432/postgres
# - CATALOG_JDBC_USER=postgres
# - CATALOG_JDBC_PASSWORD=postgres
# - CATALOG_JDBC_INITIALIZE=true
# depends_on:
# postgres:
# condition: service_healthy
networks: networks:
iceberg_net: iceberg_net: