ducklake-test

작성자: posthog

로컬 테스트를 위해 DuckLake(PostgreSQL 메타데이터를 사용하는 S3 기반 스토리지)로 duckgres를 시작합니다. duckgres를 DuckLake에 대해 테스트하거나 Fivetran을 재현할 때 사용하세요…

npx skills add https://github.com/posthog/duckgres --skill ducklake-test

Start duckgres with DuckLake configuration:

  1. Start dependencies (PostgreSQL metadata store + MinIO object storage):

    docker-compose up -d
    
  2. Kill any existing duckgres process:

    pkill -f duckgres || true
    
  3. Ensure config file exists at duckgres_local_test.yaml:

    host: "0.0.0.0"
    port: 35437
    data_dir: "./data"
    users:
      postgres: "postgres"
    extensions:
      - ducklake
    ducklake:
      metadata_store: "postgres:host=localhost port=5433 user=ducklake password=ducklake dbname=ducklake"
      object_store: "s3://ducklake/data/"
      s3_provider: "config"
      s3_endpoint: "localhost:9000"
      s3_access_key: "minioadmin"
      s3_secret_key: "minioadmin"
      s3_region: "us-east-1"
      s3_use_ssl: false
      s3_url_style: "path"
    
  4. Build and run duckgres:

    go build -o duckgres . && ./duckgres --config duckgres_local_test.yaml
    
  5. Connect with psql (in another terminal):

    PGPASSWORD=postgres psql "host=127.0.0.1 port=35437 user=postgres sslmode=require"
    

To cleanup: pkill -f duckgres && docker-compose down