diff --git a/workshop/content/docs/publishing/ogcapi-features.md b/workshop/content/docs/publishing/ogcapi-features.md index b57efce9..ad1e874e 100644 --- a/workshop/content/docs/publishing/ogcapi-features.md +++ b/workshop/content/docs/publishing/ogcapi-features.md @@ -38,44 +38,46 @@ data source. It may be helpful to open the dataset in [QGIS](https://qgis.org) while adding and updating your pygeoapi server to easily evaluate table attributes, names, spatial properties and CRS. -Let's add the file `workshop/exercises/data/osm_places_kosovo.gpkg`: +Let's add the file `workshop/exercises/data/cp-tartu2.gpkg.zip`: !!! question "Update the pygeoapi configuration" - Open the pygeoapi configuration file in a text editor. - Find the line `# START - EXERCISE 2 - osm_places`. + First, let's unzip the file [cptartu2.gpkg.zip](https://github.com/geopython/diving-into-pygeoapi/tree/main/workshop/exercises/data/cptartu2.gpkg.zip) to cptartu2.gpkg. - Add a new dataset section by uncommenting the lines up to `# END - EXERCISE 2 - osm_places`: + Then, open the pygeoapi configuration file in a text editor. + Find the line `# START - EXERCISE 2 - cadastral parcels Tartu`. + + Add a new dataset section by uncommenting the lines up to `# END - EXERCISE 2 - cadastral parcels Tartu`: ``` {.yaml linenums="1"} - osm_places-vec: + cp-tartu: type: collection - title: Places in Kosovo 2023 - description: Places in Kosovo as maintained by the Open Street Map Community + title: Tartu Cadastral Parcels + description: Cadasral parcels in downtown Tartu keywords: - - places - - Kosovo + - Cadastral parcels + - Tartu links: - - type: text/csv + - type: OGC/WFS rel: canonical title: data - href: https://download.geofabrik.de/europe/kosovo.html - hreflang: AL - extents: - spatial: - bbox: [20,41.9,21.7,43.2] - crs: http://www.opengis.net/def/crs/OGC/1.3/CRS84 + href: https://metadata.geoportaal.ee/geonetwork/srv/metadata/9949ec81-f758-42e6-9c1c-6fb604a3f053 + hreflang: EE + extents: + spatial: + bbox: [26.6, 58.3, 26.8, 58.5] + crs: http://www.opengis.net/def/crs/OGC/1.3/CRS84 providers: - type: feature name: SQLiteGPKG - data: /data/osm_places_kosovo.gpkg # place correct path here - id_field: osm_id - title_field: name - table: gis_osm_places_free_1 # table name within gpkg + data: /data/cptartu2.gpkg # place correct path here + id_field: nationalca + title_field: label + table: cptartu2 # table name within gpkg ``` Save the file and restart Docker Compose. Navigate to to evaluate whether the new dataset with -title *"Places in Kosovo 2023"* has been published. +title *"Tartu Cadastral Parcels"* has been published. !!! note diff --git a/workshop/exercises/data/README.md b/workshop/exercises/data/README.md index 11db1c6f..7e30204c 100644 --- a/workshop/exercises/data/README.md +++ b/workshop/exercises/data/README.md @@ -11,12 +11,12 @@ This directory provides sample data to demonstrate functionality. - copyright: OSM Contributors - license: ODbL -### Places Kosovo -- title: [osm_places_kosovo.gpkg](./osm_places_kosovo.gpkg) -- url: https://download.geofabrik.de/europe/kosovo.html -- description: Data converted to geopackage from kosovo-latest-free.shp.zip. The file was last modified 23-6-2023 -- copyright: OSM Contributors -- license: ODbL +### Cadastral Parcels Estonia +- title: [cptartu2.gpkg.zip](./cptartu2.gpkg.zip) +- url: https://metadata.geoportaal.ee/geonetwork/srv/metadata/9949ec81-f758-42e6-9c1c-6fb604a3f053 +- description: Data converted to geopackage from WFS. +- copyright: [Maa-amet](https://maaamet.ee) +- license: CC BY 4.0 ### Cycle Circulation Area in Florence - title: [cycle-lanes-firenze.geojson](cycle-lanes-firenze.geojson) diff --git a/workshop/exercises/data/osm_places_kosovo.gpkg b/workshop/exercises/data/osm_places_kosovo.gpkg deleted file mode 100644 index 7e7a9ec1..00000000 Binary files a/workshop/exercises/data/osm_places_kosovo.gpkg and /dev/null differ diff --git a/workshop/exercises/docker-compose.yml b/workshop/exercises/docker-compose.yml index 794e8378..a3576505 100644 --- a/workshop/exercises/docker-compose.yml +++ b/workshop/exercises/docker-compose.yml @@ -44,5 +44,5 @@ services: volumes: - ./pygeoapi.config.yml:/pygeoapi/local.config.yml - # - ./data:/data # Exercise 1 - First - Ready to pull data from here + - ./data:/data # Exercise 1 - First - Ready to pull data from here - ./plugins/process/squared.py:/pygeoapi/pygeoapi/process/squared.py # Exercise 8 diff --git a/workshop/exercises/pygeoapi.config.yml b/workshop/exercises/pygeoapi.config.yml index b7d20e86..a12c5eef 100644 --- a/workshop/exercises/pygeoapi.config.yml +++ b/workshop/exercises/pygeoapi.config.yml @@ -224,32 +224,32 @@ resources: # y_field: y ### END - EXERCISE 1 - Your First Collection -## START - EXERCISE 2 - osm_places -# osm_places-vec: +## START - EXERCISE 2 - cadastral parcels Tartu +# cp-tartu: # type: collection -# title: Places in Kosovo 2023 -# description: Places in Kosovo as maintained by the Open Street Map Community +# title: Tartu Cadastral Parcels +# description: Cadasral parcels in downtown Tartu # keywords: -# - places -# - Kosovo +# - Cadastral parcels +# - Tartu # links: -# - type: text/csv +# - type: OGC/WFS # rel: canonical # title: data -# href: https://download.geofabrik.de/europe/kosovo.html -# hreflang: AL +# href: https://metadata.geoportaal.ee/geonetwork/srv/metadata/9949ec81-f758-42e6-9c1c-6fb604a3f053 +# hreflang: EE # extents: # spatial: -# bbox: [20,41.9,21.7,43.2] +# bbox: [26.6, 58.3, 26.8, 58.5] # crs: http://www.opengis.net/def/crs/OGC/1.3/CRS84 # providers: # - type: feature # name: SQLiteGPKG -# data: /data/osm_places_kosovo.gpkg # place correct path here -# id_field: osm_id -# title_field: name -# table: gis_osm_places_free_1 # table name within gpkg -## END - EXERCISE 2 - osm_places +# data: /data/cptartu2.gpkg # place correct path here +# id_field: nationalca +# title_field: label +# table: cptartu2 # table name within gpkg +## END - EXERCISE 2 - cadastral parcels Tartu ## START - EXERCISE 3 - Coverages # firenze-terrains: