Skip to content

Commit a24310e

Browse files
author
Tik
committed
updated documentation to include example of how to configure
the collection paths inside the pydggsapi configuration when using docker-compose.yaml
1 parent cc3436a commit a24310e

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

docs/source/contribute_to_pydggsapi/index.rst

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,24 @@ docker_development.env
3939

4040
Contributors can export any environment variables defined in :doc:`Appendix </appendix/index>` to override the default value. For example, the file name of the dggs_api_config may differ from Docker's default value (`pydggsapi-config.json`).
4141

42+
Collection paths
43+
""""""""""""""""
44+
The volume `pydggsapi_datasets` is mapped to the path `/opt/local/src/pydggsapi/demo_data` of the Docker container; therefore, the collection paths defined in the pydggsapi configuration(DGGS_API_CONFIG) should follow the mapped path, where it should point to `demo_data/<data_source_name>`
45+
46+
For example:
47+
48+
.. code-block:: json
49+
50+
"est_topo_dem_10m_elva": {
51+
"filepath": "demo_data/est_topo_dem_10m_clipped_Elva_igeo7_datatree.zarr",
52+
"id_col": "zone_id",
53+
"zone_groups":{
54+
"1": "refinement_level_1",
55+
"2": "refinement_level_2",
56+
}
57+
}
58+
59+
4260
4361
Start up the Docker container with `docker-compose.yaml`
4462
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -79,6 +97,24 @@ docker_pytest.env
7997

8098
Contributors can export any environment variables defined in :doc:`Appendix </appendix/index>` to override the default value. For example, the file name of the dggs_api_config may differ from the one used in the development configuration.
8199

100+
Collection paths
101+
""""""""""""""""
102+
The volume `pytest_datasets` is mapped to the path `/opt/local/src/pydggsapi/testing_data` of the Docker container; therefore, the collection paths defined in the pydggsapi configuration(DGGS_API_CONFIG) should follow the mapped path, where it should point to `testing_data/<data_source_name>`
103+
104+
For example:
105+
106+
.. code-block:: json
107+
108+
"est_topo_dem_10m_elva": {
109+
"filepath": "testing_data/est_topo_dem_10m_clipped_Elva_igeo7_datatree.zarr",
110+
"id_col": "zone_id",
111+
"zone_groups":{
112+
"1": "refinement_level_1",
113+
"2": "refinement_level_2",
114+
}
115+
}
116+
117+
82118
Start up the Docker container with `docker-compose.yaml`
83119
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
84120

0 commit comments

Comments
 (0)