MonkeyCanCode commented on code in PR #3482: URL: https://github.com/apache/polaris/pull/3482#discussion_r2709816744
########## getting-started/rustfs/docker-compose.yml: ########## @@ -0,0 +1,116 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# + +services: + + rustfs: + image: rustfs/rustfs:latest + ports: + - "9000:9000" # S3 API port + - "9001:9001" # Console port + environment: + RUSTFS_ACCESS_KEY: rustfsadmin + RUSTFS_SECRET_KEY: rustfsadmin + RUSTFS_VOLUMES: /data + RUSTFS_ADDRESS: ":9000" + RUSTFS_CONSOLE_ENABLE: "true" + RUSTFS_CONSOLE_ADDRESS: ":9001" + healthcheck: + test: + [ + "CMD", + "sh", "-c", + "curl -f http://127.0.0.1:9000/health && curl -f http://127.0.0.1:9001/rustfs/console/health" + ] + interval: 30s + timeout: 10s + retries: 3 + start_period: 40s + + polaris: + image: apache/polaris:latest + ports: + # API port + - "8181:8181" + # Optional, allows attaching a debugger to the Polaris JVM + - "5005:5005" + depends_on: + rustfs: + condition: service_healthy + environment: + JAVA_DEBUG: true + JAVA_DEBUG_PORT: "*:5005" + AWS_REGION: us-west-2 + AWS_ACCESS_KEY_ID: rustfsadmin + AWS_SECRET_ACCESS_KEY: rustfsadmin + POLARIS_BOOTSTRAP_CREDENTIALS: POLARIS,root,s3cr3t + polaris.realm-context.realms: POLARIS + quarkus.otel.sdk.disabled: "true" + healthcheck: + test: ["CMD", "curl", "http://localhost:8182/q/health"] + interval: 2s + timeout: 10s + retries: 10 + start_period: 10s + + setup_bucket: + image: quay.io/minio/mc:latest Review Comment: That is correct with couple small syntax change where `mc` and `rc` are really for interacting with the s3-compatible storage while `aws` can do a lot more. Other than that, we will just need to set the endpoint-url for `aws` cli to `localhost:9000` then it should all works. But what is more interesting is how come there is no official image for `rc` and there are not much activities on that repo as well...even the `rc` repo is using `mc` for setting up buckets instead of using `rc` itself (but I did tested `rc` while I was working and this and it is simply drop-in replacement with change tool from `mc` to `rc`). While searching for this, I noticed there is a similar PR from Apache Iceberg for moving away from MinIO and replace with RustFS but they also ended up using `mc` for s3 interaction (https://github.com/apache/iceberg/pull/14928). Assuming `rc` will be more mature over time, it may be worth to keep `mc` for now? Or we can do docker-compose build or switch to aws cli is tha t is more preferred and reuse-able. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
