avniproject / avni-infra

Other
0 stars 0 forks source link

Automate copying of S3 media folder for a particular organisation from prod to pre-release #30

Closed petmongrels closed 1 month ago

petmongrels commented 1 month ago
mahalakshme commented 1 month ago

@petmongrels if we do this we also need to change the url in the db accordingly

@himeshr @1t5j0y you can find the best way to do the same.

petmongrels commented 1 month ago

@mahalakshme it seems this has been take care on the code of etl. when signing the urls the code, transforms the URL from prod to pre-release. it is currently working for goonj after copying the folder.

himeshr commented 1 month ago

We should no longer attempt to do this ("Copying of S3 media folder for a particular organisation from prod to pre-release"), because, there is a functioning work-around for this already, which is to configure AWS AccessKeys used in prod and prerelease environments to have access to each-other's Media buckets in S3.

In future, we can think of storing relative url paths in observations and entities and use S3 config specific to env / org to generate the absolute path, which would be a capability that could be configured at first time setup of an environment.