In map.geo.admin.ch
, GeoJSON layers consist in one data layer (geojson) and another style layer (json).
The GeoJSON layer are hosted in an AWS S3 bucket (data.geo.admin.ch
) and the style are embeded in mf-chsdi3
(https://api3.geo.admin.ch).
Meteoschweiz
needs a way to edit and test new GeoJSON styles.
Most of the map.geo.admin.ch
layers, topics and catalog configurations are hold in a few
configuration files. Theses files are statified services in map.geo.admin.ch
deployment to
the int
and prod
environment, but real services on dev
The location of these files may be controlled by the parameter config_url
.
See #4764 for discussions and implementation
In the mf-geoadmin3
directory:
make meteoconfigs/
or if integrating new layers, use the dev
service
API_URL=https://mf-chsdi3.dev.bgdi.ch make meteoconfigs/
This will copy the standards files from configs/
into a directory meteoconfigs/
and modify the
jsonStyleUrl
of MeteoSchweiz's layers using the script scripts/meteoStyleUrl.py
The server hosting the style is defined by METEO_TESTING_STYLE_BASEURL
and is currently cms.geo.admin.ch
Copy the content of the configs
directory in a suitable directory accessible
with a domain ending in bgdi.ch
, swisstopo.cloud
or geo.admin.ch
. Or simply with
make s3uploadmeteoconfig
The custom meteoconfigs will be uploaded to an AWS S3 Bucket s3://mf-geoadmin3-dev-dublin/meteoconfigs and the files will be accessible with https://mf-geoadmin3.dev.bgdi.ch/meteoconfigs
Point your browser to:
https://map.geo.admin.ch?config_url=//mf-geoadmin3.dev.bgdi.ch/meteoconfigs
Testing styles for GeoJson are to be on the location defined in the above mentionned meteoconfigs files, currently:
_https://cms.geo.admin.ch/ch.meteoschweiz/{bodLayerId}/testing/{bodLayerId}.json_
Custom resource for testing are to be hosted on
_https://cms.geo.admin.ch/ch.meteoschweiz/images/_
GeoJson data (unchangend)
bucket s3://data.geo.admin.ch Url https://data.geo.admin.ch/ch.meteoschweiz.*
Config to custom meteoconfigs (new)
Use the param: config_url S3 bucket: s3://mf-geoadmin3-dev-dublin/meteoconfigs/ URL : https://mf-geoadmin3.dev.bgdi.ch/meteoconfigs/
Testing style (moved)
old s3://data.geo.admin.ch new s3://cms.geo.admin.ch/ch.meteoschweiz url: https://cms.geo.admin.ch/ch.meteoschweiz/
Image for testing (moved) old s3://data.geo.admin.ch/ch.meteoschweiz new s3://cms.geo.admin.ch/ch.meteoschweiz URL: https://cms.geo.admin.ch/ch.meteoschweiz
Testing
https://map.geo.admin.ch/?config_url=//mf-geoadmin3.dev.bgdi.ch/meteoconfigs/
or with a custom meteoschweiz layer:
Verify that the Style file and the various images are hosted on https://cms.geo.admin.ch