MAAP-Project / Community

Issue for MAAP (Zenhub)
2 stars 1 forks source link

Add the DAAC url to the earthdata_s3_credentials output #517

Closed bsatoriu closed 2 years ago

bsatoriu commented 2 years ago

In addition to the s3 access keys currently returned by maap.aws.earthdata_s3_credentials, add a daac property that lists the url of the DAAC to ensure end users know the provenance of a given credentials object when writing algorithms.

bsatoriu commented 2 years ago

Testing requirements:

  1. On ADE Ops, update your workspace dev file to use the jupyter image mas.maap-project.org:5000/root/jupyter-image/rsgislib:v3.0.3

  2. In a jupyter notebook, run the following snippet:

    
    from maap.maap import MAAP
    maap = MAAP(maap_host='api.ops.maap-project.org')

maap.aws.earthdata_s3_credentials('https://data.lpdaac.earthdatacloud.nasa.gov/s3credentials')



3. Verify the result includes a "DAAC" property with the value "data.lpdaac.earthdatacloud.nasa.gov"
oddes commented 2 years ago

Works as expected. Able to retrieve the S3 access details for the corresponding DAAC.