-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated archiving script #109
base: main
Are you sure you want to change the base?
Conversation
print("No datasets to archive................................................") | ||
else: | ||
df = pd.DataFrame(dataset_ids) | ||
s3.Bucket("s3://deafrica-landsat/status-report/archived/").upload_file( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to use a folder on S3 dedicated to these archive logs instead of the Landsat folder @Indiphile
# Upload to AWS s3 bucket | ||
s3.Bucket("archive-deafrica-datasets").upload_file( | ||
Filename=PRODUCT_NAME + "_archived.csv", | ||
Key="crop-mask/" + PRODUCT_NAME + "_archived.csv", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How can we avoid the specific reference to "crop-mask"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To avoid referencing to the folder "crop-mask", key must include the file name only. For example in this case : if
Key=PRODUCT_NAME + "_archived.csv" , the file will uploaded to the root folder of the S3 bucket. The reason why I created the crop-mask folder is to store related product in one folder.
No description provided.