|
1 |
| - |
2 | 1 | <p align="center">
|
3 | 2 | <img width="700" src="docs/logos/eoAPI.png"/>
|
4 |
| - <p align="center">Create a full Earth Observation API with Metadata, Raster and Vector services.</p> |
| 3 | + <p align="center">Create a full Earth Observation API with Metadata, Raster, and Vector services.</p> |
5 | 4 | </p>
|
6 | 5 |
|
7 | 6 | <p align="center">
|
|
23 | 22 |
|
24 | 23 | ## **E**arth **O**bservation **API**
|
25 | 24 |
|
26 |
| -`eoAPI` combines several *state-of-the-art* projects to create a full Earth Observation API. Each service can be used and deployed independently but `eoAPI` creates the interconnections between each service: |
| 25 | +`eoAPI` combines several *state-of-the-art* projects to create a full Earth Observation API. Each service can be used and deployed independently, but `eoAPI` creates the interconnections between each service: |
27 | 26 |
|
28 | 27 | - **pgSTAC** database [https://github.com/stac-utils/pgstac](https://github.com/stac-utils/pgstac)
|
29 | 28 |
|
|
37 | 36 |
|
38 | 37 | ## 🌍 eoAPI: An Open-Source Community Project
|
39 | 38 |
|
40 |
| -`eoAPI` is proudly open-source and driven by a dedicated community of contributors. We believe in the power of open collaboration and welcome anyone to contribute, discuss, and grow this tool with us. Join the conversations on [GitHub Discussions](https://github.com/developmentseed/eoAPI/discussions) and make a difference in the Earth Observation realm. |
| 39 | +`eoAPI` is proudly open-source and driven by a dedicated community of contributors. We believe in the power of open collaboration and welcome anyone to contribute, discuss, and grow this tool. Join the conversations on [GitHub Discussions](https://github.com/developmentseed/eoAPI/discussions) and make a difference in the Earth Observation realm. |
41 | 40 |
|
42 | 41 |
|
43 | 42 | ---
|
44 | 43 |
|
45 | 44 | ## Getting started
|
46 | 45 |
|
47 |
| -- Clone the repository: `git clone https://github.com/developmentseed/eoAPI.git` |
48 |
| -- Navigate to the project: `cd eoAPI` |
49 |
| -- Run services with `docker compose up` |
50 |
| -- Follow the [MAXAR open data demo](https://github.com/vincentsarago/MAXAR_opendata_to_pgstac) (or get inspired by the other [demos](./demo/)) to load some data into eoAPI |
51 |
| -- Check out the [Search Viewer](http://localhost:8081/index.html), and the API documentation ([STAC Metadata](http://localhost:8081/docs), [Raster Tiles](http://localhost:8082/docs), [Vector Tiles](http://localhost:8083/api.html)) |
| 46 | +The easiest way to start exploring the different eoAPI services is with *Docker*. Clone this repository and start the multi-container *Docker* applications using `Compose`: |
| 47 | + |
| 48 | +``` |
| 49 | +git clone https://github.com/developmentseed/eoAPI.git |
| 50 | +cd eoAPI |
| 51 | +docker compose up |
| 52 | +``` |
| 53 | + |
| 54 | +Once the applications are *up*, you'll need to add STAC **Collections** and **Items** to the PgSTAC database. If you don't have, you can use the follow the [MAXAR open data demo](https://github.com/vincentsarago/MAXAR_opendata_to_pgstac) (or get inspired by the other [demos](https://github.com/developmentseed/eoAPI/tree/main/demo)). |
| 55 | + |
| 56 | +Then you can start exploring your dataset with: |
| 57 | + |
| 58 | + - the STAC Metadata service [http://localhost:8081](http://localhost:8081) |
| 59 | + - the Raster service [http://localhost:8082](http://localhost:8082) |
| 60 | + |
| 61 | +If you've added a vector dataset to the `public` schema in the Postgres database, they will be available through the **Vector** service at [http://localhost:8083](http://localhost:8083). |
| 62 | + |
| 63 | +## Deployment |
| 64 | + |
| 65 | +This repository has current runtimes that are consistently updated with new functionality. |
| 66 | + |
| 67 | +The services can be deployed locally via docker with `docker compose up`. |
| 68 | + |
| 69 | +Two Infrastructure as Code (IaC) repositories are available: |
| 70 | +- [eoapi-cdk](https://github.com/developmentseed/eoapi-cdk): A set of AWS CDK constructs to deploy eoAPI services |
| 71 | +- [eoapi-k8s](https://github.com/developmentseed/eoapi-k8s): IaC and Helm charts for deploying eoAPI services on AWS and GCP |
| 72 | + |
| 73 | +Finally, [eoapi-template](https://github.com/developmentseed/eoapi-template) is an AWS CDK app that shows how to configure the eoapi-cdk constructs. |
| 74 | + |
| 75 | +Alternatively, you may install the libraries locally: |
| 76 | + |
| 77 | +<details> |
52 | 78 |
|
53 |
| -Alternatively, you may launch the application locally: |
54 | 79 | ```bash
|
55 | 80 | python -m pip install --upgrade virtualenv
|
56 | 81 | virtualenv .venv
|
57 | 82 | source .venv/bin/activate
|
58 | 83 |
|
59 |
| -python -m pip install "psycopg[binary,pool]" uvicorn |
60 |
| -python -m pip install runtime/eoapi/{SERVICE} # SERVICE should be one of `raster, vector, stac` |
61 |
| - |
62 | 84 | export DATABASE_URL=postgresql://username: [email protected]:5439/postgis # Connect to the database of your choice
|
63 | 85 |
|
64 |
| -.venv/bin/uvicorn eoapi.{SERVICE}.app:app --port 8000 --reload |
| 86 | +python -m pip install uvicorn |
| 87 | + |
| 88 | +############################################################################### |
| 89 | +# Install and launch the application |
| 90 | +# Select one of the following |
| 91 | + |
| 92 | +############################################################################### |
| 93 | +# STAC |
| 94 | +python -m pip install "psycopg[binary,pool]" stac-fastapi-pgstac |
| 95 | +.venv/bin/uvicorn stac_fastapi.pgstac.app:app --port 8081 --reload |
| 96 | + |
| 97 | +############################################################################### |
| 98 | +# RASTER |
| 99 | +python -m pip install "psycopg[binary,pool]" titiler-pgstac |
| 100 | +.venv/bin/uvicorn titiler.pgstac.main:app --port 8082 --reload |
| 101 | + |
| 102 | +############################################################################### |
| 103 | +# VECTOR |
| 104 | +python -m pip install tipg |
| 105 | +.venv/bin/uvicorn tipg.main:app --port 8083 --reload |
65 | 106 | ```
|
66 | 107 |
|
67 |
| -Note: services might have incompatible dependencies which you can resolve by using a virtual environment for each service |
| 108 | +Note: python libraries might have incompatible dependencies, which you can resolve by using a virtual environment for each ones |
68 | 109 |
|
69 |
| ---- |
| 110 | +</details> |
70 | 111 |
|
71 |
| -## Deployment |
| 112 | +## Custom runtimes |
72 | 113 |
|
73 |
| -This repository has current runtimes that are consistently updated with new functionality. |
| 114 | +The eoAPI repository hosts customized versions of each base service which can work in parallel or in combination with each other. |
74 | 115 |
|
75 |
| -The services can be deployed locally via docker with `docker-compose up`. The official runtimes can be launched with `docker-compose -f docker-compose.yml -f docker-compose.official.yml up stac-fastapi titiler-pgstac tipg`. |
| 116 | +eoAPI custom runtimes can be launched with docker |
76 | 117 |
|
77 |
| -Two Infrastructure as Code (IaC) repositories are available: |
78 |
| -- [eoapi-cdk](https://github.com/developmentseed/eoapi-cdk): A set of AWS CDK constructs to deploy eoAPI services |
79 |
| -- [eoapi-k8s](https://github.com/developmentseed/eoapi-k8s): IaC and Helm charts for deploying eoAPI services on AWS and GCP |
| 118 | +``` |
| 119 | +docker compose -f docker-compose.custom.yml --profile gunicorn up |
| 120 | +``` |
80 | 121 |
|
81 |
| -Finally, [eoapi-template](https://github.com/developmentseed/eoapi-template) is an AWS CDK app that shows how to configure the eoapi-cdk constructs. |
| 122 | +Alternatively, you may launch the application locally: |
| 123 | +```bash |
| 124 | +python -m pip install --upgrade virtualenv |
| 125 | +virtualenv .venv |
| 126 | +source .venv/bin/activate |
| 127 | + |
| 128 | +python -m pip install "psycopg[binary,pool]" uvicorn |
| 129 | +python -m pip install runtime/eoapi/{SERVICE} # SERVICE should be one of `raster, vector, stac.` |
| 130 | + |
| 131 | +export DATABASE_URL=postgresql://username: [email protected]:5439/postgis # Connect to the database of your choice |
| 132 | + |
| 133 | +.venv/bin/uvicorn eoapi.{SERVICE}.app:app --port 8000 --reload |
| 134 | +``` |
| 135 | + |
| 136 | +Note: services might have incompatible dependencies, which you can resolve by using a virtual environment for each service |
82 | 137 |
|
83 | 138 | ## Contribution & Development
|
84 | 139 |
|
85 |
| -We highly value and rely on our community! Whether you're an expert or just getting started, you can make a difference. Here's how: |
| 140 | +We highly value and rely on our community! You can make a difference whether you're an expert or just getting started. Here's how: |
86 | 141 |
|
87 | 142 | - **Contribute**: Check out our [CONTRIBUTING.md](https://github.com/developmentseed/eoAPI/blob/main/CONTRIBUTING.md) guide to understand how you can contribute.
|
88 | 143 | - **Engage in Discussions**: Share your ideas, ask questions, or provide feedback through [GitHub Discussions](https://github.com/developmentseed/eoAPI/discussions). This is where most of our project conversations take place.
|
|
0 commit comments