The EarthChem Portal (ECP) is a one-stop shop for geochemistry data of the solid earth. It provides integrated search results by federating multiple data systems—including PetDB, SedDB, GEOROC, NavDat, USGS, and GANSEKI—and features mapping and visualization tools.
This repository offers a portable, Docker-based infrastructure to run the ECP frontend applications, which include both the ECP Web and ECP WFS servers.
Follow these steps to configure and deploy the ECP web server:
-
Obtain ECP Database Credentials
Ensure you have the necessary database credentials for connecting to the ECP database. -
Create
config.inc.php
In theweb_server/dbconfigdirectory, create a file namedconfig.inc.phpwith the following contents:<? $dbusername = "****"; $dbpassword = "******"; $dbname = "****"; $dbserver = "******"; $readonly = ""; ?>
-
Create
config.inc.python.json
In theweb_server/dbconfigdirectory, create a file namedconfig.inc.python.jsonwith the following contents:{ "pg_connection": { "host": "******", "user": "****", "passwd": "****", "db": "****" } } -
Update Docker Compose Configuration In the
docker-compose.yml
modify the source paths (e.g., on lines 11 and 14) to point to the correct directories:source: web_server_data/plots source: web_server_data/hist2dplots
-
Deploy the Web Server Container Build and run the web server container using Docker Compose
docker compose -f docker-compose.yml up -d --build ecp_web
To configure the ECP WFS server, complete the following steps:
- Modify the
DockerfileIn thewfs_server
comment out line 12 by changing it to:# COPY ./wfs_server/geoserver-users.xml /usr/local/tomcat/webapps/wfs/data/security/usergroup/default/users.xml - Update Docker Compose Configuration In the
docker-compose.yml
update the source path on line 26 to match your directory structure:source: wfs_server_data/logs
- Deploy the WFS Server Container Build and run the web server container using Docker Compose
docker compose -f docker-compose.yml up -d --build ecp_wfs
- Change the
adminpassword in GeoServer- Log into the GeoServer UI with the default
adminaccount(username:admin, password:geoserver). - Change the
adminpassword
- Log into the GeoServer UI with the default
- Update ECP database credential
- Navigate to the
Datatab on the left navigation panel and click on theStoreslink. - You will find a record(workspace:ECP,Store Name:ECP Postgis, Type:PostGIS) on the page 'Stores' and clik on the 'ECP Postgis' link.
- Update
Connection Parameterson the pageEdit Vector Data Source
- Navigate to the
```bash
docker build --file web_server/Dockerfile --platform linux/amd64 --no-cache --tag ecp_web:bookworm-slim .
```
```bash
docker build --file wfs_server/Dockerfile --platform linux/amd64 --no-cache --tag ecp_wfs:9.0.104-jre17-temurin-noble .
```
```bash
docker compose -f docker-compose-with-image.yml up
```
Contains fonts for various map interfaces.
Contains code for interacting with geopass system.
Contains headers/footers for all ECP pages.
Contains client-side scripts.
Library for creating SVG graphs.
Set advanced options for search output.
Advanced search output.
Response for alteration rock Ajax.
Map file for overlaying MGDS bathymetry.
Mapscript for overlaying MGDS bathymetry.
Map file for overlaying MGDS bathymetry on south pole.
Return monthly citation statistics.
Return quarterly citation statistics.
Clear age for search query.
Clear chemistry for search query.
Clear cruise id for search query.
Clear geology for search query.
Clear igsn for search query.
Clear keyword for search query.
Clear location for search query.
Clear mineral for search query.
Clear ocean feature for search query.
Clear reference for search query.
Clear rocktype for search query.
Clear sample ID for search query.
Clear volcano for search query.
Helper for getting list of datasources
Database abstraction class loader.
Delete saved user query.
Map file for creating dynamic map with search results.
Map file for creating dynamic map with search results on south pole.
Map search interface.
South pole map search interface.
Dynamic mapscript for 4326 projection.
Dynamic mapscript for polar projection.
Output static map for search query.
Output static polar map for search query.
Helper for fetching pkey on page.
Helper for rock classification Ajax calls.
Helper for rock classification Ajax calls.
Helper for rock classification Ajax calls.
Helper for rock classification Ajax calls.
Helper for rock classification Ajax calls.
ECP glossary system.
Add glossary entry.
Delete glossary entry.
Publish glossary entry.
Unpublish glossary entry.
Glossary RSS feed.
Output harker diagram from search results.
Output SVG harker diagram from search results.
Output 2D histogram harker diagram from search results.
Output 2D histogram harker diagram from search results(python 3).
Output 2D histogram TAS diagram from search results.
Output 2D histogram harker diagram from search results(python 3).
Output current ECP holdings for inclusion on IEDA page.
ECP landing page.
Legend for Google Earth.
Wrapper for LEPR counts.
Slider interfaces for LEPR.
Log download from search query.
Log citation information for downloads.
Login to the ECP system via GeoPass.
Logout of ECP system via GeoPass.
Detail for map interface.
Interface for MELTS interoperability.
Response for metamorphic rock Ajax.
Output image of ocean feature polygon.
Response for ore rock Ajax.
Mapserver file for MGDS bathymetry on south polar projection.
Helper script for creating various queries for given search pkey.
Output basick html results with no output options.
Output html table with all references for given query.
Output XLS file with all references for given query.
Output result options for given query pkey.
Response for rockname Ajax.
Saved queries user interface.
Save query for saved queries interface.
Main search landing page.
Update search query with form input.
Helper file for keeping track of current search criteria.
Display polygon for search page (Polar projection).
Display polygon for search page.
Update search query with form input.
Response for sedimentary rockname Ajax.
UI for setting age parameters.
UI for setting chemistry parameters.
UI for setting cruise ID.
UI for setting description.
UI for setting geology parameters.
UI for setting IGSN.
UI for setting keyword.
UI for setting location parameters.
UI for setting map parameters.
UI for setting material parameters.
UI for setting method parameters.
UI for setting mineral.
UI for setting normalization parameters.
UI for setting ocean feature.
UI for setting reference parameters.
UI for setting rock type parameters.
UI for setting sample ID.
UI for setting volcano parameters.
Display single sample on map.
Static map of search results.
Static polar map of search results.
Helper file for limiting results to specific federated partner databases.
Landing page for setting up new search.
Output SVG TAS diagram for given query.
Output raster TAS diagram for give query.
Update holding statistics for ECP database.
Update query items for search UI.
Response for vein rockname Ajax.
Output map with volcano.
Documentation for WFS services.
Response for vein rockname Ajax.