BERDL MinIO Skill
Overview
Use this skill to work with BERDL MinIO from local tools.
It handles credential sourcing, MinIO client setup, and object transfer operations.
Step 0: Environment Check
Run before anything else:
python scripts/berdl_env.py --check
If --check reports off-cluster and not ready, follow the printed next steps. The MinIO endpoint (minio.berdl.kbase.us) is only reachable through the proxy chain off-cluster, so this check is mandatory.
Preconditions
KBASE_AUTH_TOKENset in environment or.env.mc(MinIO client) installed. Check withcommand -v mc. Install with:
- macOS:
brew install minio/stable/mcor download directly:
curl -sSL https://dl.min.io/client/mc/release/darwin-arm64/mc -o /usr/local/bin/mc && chmod +x /usr/local/bin/mc
- Linux:
curl -sSL https://dl.min.io/client/mc/release/linux-amd64/mc -o /usr/local/bin/mc && chmod +x /usr/local/bin/mc
- Proxy running (when off-cluster): MinIO is not directly reachable from external networks. See the berdl-query skill's
references/proxy-setup.mdfor setup instructions.
Credential Strategy
Use credentials in this order:
- Existing
S3_ACCESS_KEYandS3_SECRET_KEYin environment or.env. These were once calledMINIO_ACCESS_KEY/MINIO_SECRET_KEY; that spelling is gone from current pods and the tooling no longer reads it. - Derive credentials from BERDL remote environment using
berdl-remote(authenticated byKBASE_AUTH_TOKEN).
Workflow
- Resolve credentials:
python scripts/get_minio_creds.py --shell- If remote bootstrap is needed:
python scripts/get_minio_creds.py --bootstrap-remote --shell - To load creds into your shell:
eval "$(python scripts/get_minio_creds.py --shell)"
- Configure
mcalias:
bash scripts/configure_mc.sh --berdl-proxy- Without proxy (on-cluster only):
bash scripts/configure_mc.sh
- Move files with
mc.
Important: Every mc command needs https_proxy set when off-cluster, not just the alias setup. Either export it in your shell or prefix each command:
```bash
export https_proxy=http://127.0.0.1:8123
export no_proxy=localhost,127.0.0.1
mc ls berdl-minio/cdm-lake/users-general-warehouse/<user>/exports/
mc cp --recursive berdl-minio/cdm-lake/.../run_20260217 ./exports/run_20260217
mc cp --recursive ./local_data berdl-minio/cdm-lake/.../uploads/local_data
```
Scripts
Only the scripts listed below exist. Do not invent script names — if you need behavior that's not covered, ask the user.
scripts/berdl_env.py: environment check entrypoint (Step 0).scripts/get_minio_creds.py: resolve MinIO keys locally or via BERDL remote context.scripts/configure_mc.sh: configure MinIO CLI alias and test connectivity.- Supports
--berdl-proxyto route throughhttp://127.0.0.1:8123(required when off-cluster).
References
references/minio-endpoints.md: environment endpoints and path patterns.- See berdl-query
references/proxy-setup.mdfor proxy chain setup.
Safety Rules
- Never print full secrets in final user-facing summaries unless explicitly requested.
- Do not commit credentials into repository files.
- Prefer short-lived retrieval and local shell export for active sessions.