graflo.object_storage.config¶
S3-compatible endpoint configuration (SeaweedFS, AWS S3, MinIO, etc.).
Used by boto3 S3 clients. Not a graph database target.
:meth:S3EndpointConfig.from_docker_env reads docker/seaweedfs, the S3
service this repository ships.
Classes¶
S3EndpointConfig
¶
Bases: BaseModel
Credentials and endpoint for any S3-compatible API (boto3).
Source code in graflo/object_storage/config.py
Attributes¶
access_key = Field(description='S3 access key id.')
class-attribute
instance-attribute
¶
bucket = Field(default='graflo-staging', description='Default bucket.')
class-attribute
instance-attribute
¶
endpoint_url = Field(description='Base URL for the S3 API, e.g. http://127.0.0.1:8333')
class-attribute
instance-attribute
¶
model_config = ConfigDict(extra='forbid')
class-attribute
instance-attribute
¶
region = Field(default='us-east-1', description='AWS region string passed to boto3 (us-east-1 for a local S3 service).')
class-attribute
instance-attribute
¶
secret_key = Field(description='S3 secret access key.')
class-attribute
instance-attribute
¶
Methods:¶
from_docker_env(docker_dir=None)
classmethod
¶
Load the S3 service settings of docker/seaweedfs.
Reads <docker_dir>/.env.example when it exists; every setting has a default
matching the bundled compose file, whose S3 API accepts any key pair, so
the file is optional.
Settings: S3_ENDPOINT (or S3_PROTOCOL, S3_HOSTNAME,
S3_API_PORT), S3_ACCESS_KEY, S3_SECRET_KEY, S3_BUCKET
and AWS_REGION.
Source code in graflo/object_storage/config.py
to_files_conn_config()
¶
The files connection of :attr:bucket, as a connection provider stores it.