I've successfully added a custom gridset using the Geoserver REST API, but now I don't know how to add it as the default caching grid set. In addition I would also like to adjust the default caching formats for coverage, vector and other.
I've tried finding something in the documentation, without success. I've also tried a PUT request to /gwc/rest/config:
geoserver_request "$GEOSERVER_URL/gwc/rest/config" "$(cat gwcConfig.xml)" PUT
gwcConfig.xml:
<gwcConfiguration>
<version>1.0</version>
<defaultCachingGridSetIds>
<string>EPSG:2056</string>
</defaultCachingGridSetIds>
<defaultCoverageCacheFormats>
<string>image/png</string>
<string>image/jpeg</string>
</defaultCoverageCacheFormats>
<defaultVectorCacheFormats>
<string>image/png</string>
<string>image/jpeg</string>
</defaultVectorCacheFormats>
<defaultOtherCacheFormats>
<string>image/png</string>
<string>image/jpeg</string>
</defaultOtherCacheFormats>
</gwcConfiguration>