Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Running a maintained, up-to-date instance of Earthdata Search without incurring the cost of hardware or administration
  • The ability to present a limited set of collections to users, scoped to only those relevant to the target user community
  • Presentation of additional logos, navigation, and page titles
  • A simple URL for the portal (parameter https://search.sit.earthdata.nasa.gov/search?portal/=your-portal-name)
       this is backwards compatible with the previously established  with bookmark-able links within the portale.g. (https://search.earthdata.nasa.gov/portal/your-portal-name)
  • Interoperability with the full Earthdata Search site, allowing users to optionally and easily search the full list of collections, and see their saved projects and past retrievals from the portal in Earthdata Search
  • Inclusion of custom provider-developed CSS and/or Javascript resources into every page to make arbitrary updates to page style and add or remove featuresconfiguration allowing for the manipulation of basic Earthdata Search user interface elements such as showing the only-granules and non-eosdis additional filter checkboxes

The remainder of this document will walk through the process of creating and configuring a portal.

...

We're here to help, and we want to understand community needs so we can refine our features. Email Valerie Dixon (valerie.dixon@nasadixon@nasa.gov) to get started with your portal and get in touch with developers.

...

A significant amount of configuration can be done through this config.json file. You can view an example configurations at configuration at https://github.com/nasa/earthdata-search/treeblob/mastermain/portals/simpledefault/config.json and or browse https://github.com/nasa/earthdata-search/tree/mastermain/portals/complex/config.json. to see all portal configurations. Here is an explanation of the configuration:

KeyData TypeExplanation
features
ObjectFeature configuration
    advancedSearch
BooleanEnable/disable the advanced search feature
    authentication
BooleanEnable/disable all features that rely on authentication (logging in/projects)
    featureFacets
ObjectFeature Facet configuration
        showAvailableFromAwsCloud
BooleanShow/hide the Available from AWS Cloud feature facet
        showCustomizable
BooleanShow/hide the Customizable feature facet
        showMapImagery
BooleanShow/hide the Map Imagery feature facet
footer
ObjectFooter configuration
 
  displayVersionBooleanDisplay the current application version in the footer   
   attributionText
StringText to display in the footer, example "NASA Official: ..."
    displayVersion
BooleanDisplay the current application version in the footer
    primaryLinks
Array

Array of links to display on the left side of the footer

This array is made up of objects with two values:

{
 
   
title
 href: "The 
viewable
URL 
text
the 
of
link 
the
will 
link
follow",
 

 
   
 
 
href
title: "The 
URL
viewable text of the link
will
" 
follow"

}
    secondaryLinks
ArrayArray of links to display on the right side of the footer. This uses the same objects as `primaryLinks`
hasStyles
hasLogo
Boolean

This tells EDSC if it needs to load a "styles.scss" file,  see Advanced Configuration.

Toggle to for a logo to appear on the portal context sidebar header and in the the portal browser modal (if it is enabled, see portalBrowser boolean field).
hasStyles
hasScripts
BooleanThis tells EDSC if it needs to load a "
scripts
styles.
js
scss" file
, see Advanced Configuration.
moreInfoUrl
logo
Object (Optional)Configuration for a logo to appear to the right of the NASA logo in the upper left of the page. If omitted, no logo will be added.
    id
String (Optional)This is the id attribute of the <a> tag that houses the logo image, see Advanced Configuration.
    image
String (Optional)Path to logo image. This is not recommended, please see Advanced Configuration for the preferred method of adding the logo image.    link
String (Optional)This is the URL that users will be sent to when clicking on the logo image. If no value is provided clicking on the logo image will return the user to the EDSC portal home (/portal/example/search)
.
    title
String (Optional)This text is set as the title attribute in the <a> tag that houses the logo image, it will be displayed when you user hovers their mouse over the logo
org
String (Optional)A short string representing the organization that replaces "Earthdata" in the top-left of the site toolbar. If omitted, it will just say "Earthdata
.
"
pageTitle
StringThis will appear after the default portal's
`org` and `title`
`pageTitle` in the HTML page title (see in the tab of the browser). For example if EDSC is the default portal then the page title will be "Earthdata Search :: <pageTitle> | Earthdata Search"
parentConfig
StringThe parent config file for this portal. If your portal will be deployed to EOSDIS Earthdata Search this value should be "edsc". If not, set this to "default".
portalBrowser
BooleanToggle to set whether the portal will appear as a listed portal in the portal browser modal
query
Object (Optional)

These parameters are used to filter the list of collections exposed in the portal. 

Current supported values:

  • consortium (Array of strings)
  • dataCenter (String)
  • echoCollectionId (this narrows the results to a single collection, only used as an example) (String)
  • hasGranulesOrCwic (set to null to include all collections)
  • project (String)
  • tagKey (String or String array)

One common pattern is to show all the datasets in a dataCenter. This example shows the ORNL DAAC portal configuration:

  "query": {
    "dataCenter": "ORNL_DAAC",
    "hasGranulesOrCwic": null
  },

Likewise, for Science Project-focused portals, here is the AIRMOSS project portal:

  "query": {
    "project": "AirMOSS",
    "hasGranulesOrCwic": null
  },

A more nuanced approach can be applied using tags in CMR.  Here is an example from the Suborbital portal using the tagKey parameter (note that the tagKey can contain simple wildcards):

  "query": {
    "tagKey": ["gov.nasa.impact.*"],
    "hasGranulesOrCwic": null
  },

If you need support of another CMR query parameter, please contact us.

Refer to the CMR documentation for information on parameters:
https://cmr.earthdata.nasa.gov/search/site/search_api_docs.html 

title
Object

Object containing the primary and secondary title for the portal.

    primary
String
(Optional)A short string to be used when referring to the portal. This will appear verbatim where the word "Search" is in the top-left of the site toolbar and will appear in various other places as "Example Portal" when referring to the portal. If omitted, a capitalized version of the portal ID will be used, i.e. "Example."
The primary field in the title object will be displayed on the portal browser modal as the top identifier. It will also be displayed on the top left portal browser context sidebar header and on the leave portal button on the bottom of the collection search results while inside of a portal.
    secondary
StringThe secondary field in the title object will be displayed below the primary on the portal browser modal and in parentheses on the top left portal browser context sidebar header. It is meant to be the fullname of the project, endeavor, organization behind the creation of the portal.
ui
ObjectUI configurations
   
showOnlyGranulesCheckbox
 showNonEosdisCheckbox
Boolean
Only include collections with granules
   
showNonEosdisCheckbox
 showOnlyGranulesCheckbox
BooleanShow/hide the "
Include non-EOSDIS collections
    showTophat
BooleanShow/hide Tophat

Inheriting Configuration Values

Portals now will inherit configuration values from a parent configuration. See the "parentConfig" value above. This allows you to use all of a parent's config values and keep your portal configuration portal configuration minimal if your portal needs most of the same features as the parent configuration.

...

Adding Portal Logo and Configuring Portal Logo Dimensions

Portals allow authors to provide SASS styles and JavaScript to run on each page within the portal. These can be useful for altering the page style, hiding unnecessary features, or adding new features that do not make sense for inclusion in Earthdata Search. You can do essentially anything that can be done with Javascript or SASSto configure the logo styling of the portal.

If you are authoring something complex or if you have needs that you feel would be better addressed at the basic configuration levelyou have need to add more advanced custom functionality or a setting you think ought to be included as a basic configuration level on the portal, please reach out to our developers, who Chris Lynnes (christopher.s.lynnes@nasa.gov) can put you in touch with.

styles.scss

Setting up a Custom Portal Logo:

This is the preferred way to To add a new logo image, which are displayed next in the left toolbar to the NASA meatball, centered vertically. You can reference the existing portals in the ./portals/... directory for examples of how this works in practice.establish the search context or on the  the portal browser modal (optionally. see portalBrowser boolean config field).

  1. Set hasStyles to true in config.jsonSet id, link, and title in the logo section of
  2. the Ensure that the hasLogofield is set to true on config.json
  3. Save your image (s) into the ../portals/myportal/images/ directory and name this file logo.png
  4. If in In the logo section of your config.json file, you set the "id" field to "example-logo" hasLogo to true, then you would use this SASS CSS rule to load that image:

    #example#portal-logo logo {
      height: 25px; // set the correct height for your logo 
      width: 54px // set the correct width for your logo ;
      background-image: url('./images/<portal name>-logo.[png|jpeg]') //Set the path to the logo png file;
    }
Custom Logo Best Practices:
  • Images will be displayed at a maximum of

...

  • 75px tall by

...

  • 75px wide. Logos should be trimmed to

...

  • fit

...

  • within those

...

  • dimensions.

...

  • It is highly encouraged that images be provided at twice their displayed size (50px x 114px maximum) for better display on high resolution screens.
  • Images

...

  • must be named

...

  • logo.

...

  • png

...

Adding Portal to the index.js list

In the /portals directories you will need to add the name of your portal to the portals list in the index.js file. The string you enter should be the same as the name of the directory for your portal. Portals should be added in alphabetical order.
    

portals [
  'above',
    ...
  'your-portal-example'
]

scripts.js

This file will load and execute any JavaScript you need in EDSC. Because EDSC is a single page React application, the uses of this file are limited. But, you can use it to pre-load and second version of your logo to be used when the user hovers over the image. To do this refer to https://github.com/nasa/earthdata-search/tree/master/portals/ornldaac/scripts.js and https://github.com/nasa/earthdata-search/tree/master/portals/ornldaac/styles.scss.

...

Step 5:  Incorporating Changes into Earthdata Search

...

  1. When a pull request is merged, it starts a build. Within a few minutes of the build becoming green, that those changes gets get pushed to our SIT environment for testing:   https://search.sit.earthdata.nasa.gov
  2. Every other Wednesday, our current UAT environment (https://search.uat.earthdata.nasa.gov) is deployed to our operational environment (https://search.earthdata.nasa.gov) and our SIT environment from the previous Monday is deployed to our UAT environment.

...