balena-io / open-balena

Open source software to manage connected IoT devices at scale
https://balena.io/open
GNU Affero General Public License v3.0
1.03k stars 162 forks source link

configure and connect minio buckets #204

Closed matiasAS closed 2 days ago

matiasAS commented 1 month ago

Hello, 1 day ago I saw that there was an important update to openbalena and I immediately started testing it. But I am very confused and I lack a clear guide on how to connect Minio to the new version. First, because in the previous version it was clear how all the environment variables were defined in the activate file, but now I am not clear if they are missing, I have to modify files, I am missing a lot of information.

I would appreciate your help clarifying this point or adding it directly to the readme or updating this part to make it easier. Greetings Matias @florianluediger @roman-mazur @wrboyce @relaxdiego @dfunckt

ab77 commented 1 month ago

@matiasAS Hello

how to connect Minio to the new version

Well, the S3 container is defined in the composition here. If you are customising your services however, you would need to set all its env-vars correctly (e.g.):

BUCKETS=registry-data;web-resources
REGISTRY2_S3_REGION_ENDPOINT=s3.<your domain>
WEBRESOURCES_S3_HOST=s3.<your domain>

REGISTRY2_S3_KEY=<random value>  # e.g. openssl rand -hex 16
REGISTRY2_S3_SECRET=...

S3_MINIO_ACCESS_KEY=${REGISTRY2_S3_KEY}
S3_MINIO_SECRET_KEY=${REGISTRY2_S3_SECRET}

WEBRESOURCES_S3_ACCESS_KEY=${REGISTRY2_S3_KEY}
WEBRESOURCES_S3_SECRET_KEY=${REGISTRY2_S3_SECRET}

.. how you end up implementing this is up to you however

An alternative may be to stand up a new instance separately using the latest changes, copy data across, test and repoint your DNS.