Skip to content

Instantly share code, notes, and snippets.

View fvanderbiest's full-sized avatar

François Van Der Biest fvanderbiest

View GitHub Profile
@fvanderbiest
fvanderbiest / GEOR_custom.js
Last active December 14, 2015 02:49
Google Maps in geOrchestra viewer
/**
* Constant: MAP_SCALES
* {Array} The map's scales.
* Defaults to GeoBretagne GWC compliant scales
*/
MAP_SCALES : [
846.372882141,
1692.745764282,
3385.491528564,
6770.983057129,
@fvanderbiest
fvanderbiest / gist:5831034
Last active December 18, 2015 19:09
GeoServer WMS opaque layer property support
diff --git a/src/main/src/main/java/org/geoserver/catalog/LayerInfo.java b/src/main/src/main/java/org/geoserver/catalog/LayerInfo.java
index 995810c..4852912 100644
--- a/src/main/src/main/java/org/geoserver/catalog/LayerInfo.java
+++ b/src/main/src/main/java/org/geoserver/catalog/LayerInfo.java
@@ -161,7 +161,7 @@ public interface LayerInfo extends PublishedInfo {
/**
* Sets the queryable status
- *
+ *
diff --git a/server-deploy/pom.xml b/server-deploy/pom.xml
index b3cf9d5..f487e1b 100644
--- a/server-deploy/pom.xml
+++ b/server-deploy/pom.xml
@@ -150,6 +150,13 @@
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
+ <artifactId>geofence</artifactId>
+ <version>${project.version}</version>
@fvanderbiest
fvanderbiest / gist:11215220
Created April 23, 2014 13:28
Element 's:http' cannot have character [children], because the type's content type is element-only
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.3: Element 's:http' cannot have character [children], because the type's content type is element-only.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:195)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:131)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:384)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:318)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(XMLSchemaValidator.java:423)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.reportSchemaError(XMLSchemaValidator.java:3188)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.elementLocallyValidComplexType(XMLSchemaValidator.java:3151)
at com.sun.org.apach
@fvanderbiest
fvanderbiest / gist:11217409
Created April 23, 2014 14:28
locking down georchestra
diff --git a/security-proxy/WEB-INF/applicationContext-security.xml b/security-proxy/WEB-INF/applicationContext-security.xml
index 5257608..e4e20f4 100644
--- a/security-proxy/WEB-INF/applicationContext-security.xml
+++ b/security-proxy/WEB-INF/applicationContext-security.xml
@@ -15,6 +15,7 @@
<s:intercept-url pattern=".*\?.*casLogin.*" access="ROLE_SV_USER,ROLE_SV_EDITOR,ROLE_SV_REVIEWER,ROLE_SV_ADMIN" />
<s:intercept-url pattern="/extractorapp/admin/.*" access="ROLE_ADMINISTRATOR" />
<s:intercept-url pattern="/extractorapp/.*" access="ROLE_MOD_EXTRACTORAPP" />
+ <s:intercept-url pattern="/header/.*" access="IS_AUTHENTICATED_ANONYMOUSLY" />
<s:intercept-url pattern="/geofence/.*" access="ROLE_ADMINISTRATOR" />
@fvanderbiest
fvanderbiest / gist:f5d5e467c7ca004ce73b
Created May 2, 2014 06:45
geoserver reload script
#!/usr/bin/env python
#-*- coding: utf-8 -*-
"""This is a script that we use to reload geoserver catalogs when load balancing them"""
"""
Copyright 2014 Camptocamp. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are
permitted provided that the following conditions are met:
@fvanderbiest
fvanderbiest / gist:5a80f879091b97cc25c0
Created October 7, 2014 11:58
operatesOnIdentifier
curl -X POST -H "Content-type: application/xml" -d '<?xml version="1.0" encoding="UTF-8"?><csw:GetRecords xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" service="CSW" version="2.0.2" resultType="results_with_summary" startPosition="1" maxRecords="20" xmlns:gmd="http://www.isotc211.org/2005/gmd"><csw:Query typeNames="csw:Record"><csw:ElementSetName>full</csw:ElementSetName><csw:Constraint version="1.1.0"><ogc:Filter xmlns:ogc="http://www.opengis.net/ogc"><ogc:PropertyIsLike wildCard="*" singleChar="." escapeChar="!"><ogc:PropertyName>operatesOnIdentifier</ogc:PropertyName><ogc:Literal>afeb3f59-136c-4855-b1c7-42c7b46cc9b5</ogc:Literal></ogc:PropertyIsLike></ogc:Filter></csw:Constraint></csw:Query></csw:GetRecords>' http://geobretagne.fr/geonetwork/srv/fre/csw
@fvanderbiest
fvanderbiest / gist:2ffb679457f705b43ed4
Created October 31, 2014 11:05
POI table - postgresql - postgis - index - gist - trigger
CREATE TABLE pois (
id serial primary key,
lon numeric(9,6),
lat numeric(9,6),
name character varying(255),
geom geometry(Point,3857) -- EPSG:3857 is the spherical mercator projection
);
CREATE INDEX geom_idx ON pois USING GIST (geom GIST_GEOMETRY_OPS);
CREATE OR REPLACE FUNCTION update_geom() RETURNS "trigger" AS
var w = window, n = w.navigator,
onMobile = (('ontouchstart' in w) ||
(('maxTouchPoints' in n) && n.maxTouchPoints > 1) ||
(('msMaxTouchPoints' in n) && n.msMaxTouchPoints > 1));
@fvanderbiest
fvanderbiest / haproxy.cfg
Last active December 18, 2018 22:15
HAProxy config for geoserver load balancing, with a master instance
global
chroot /var/lib/haproxy
daemon
group haproxy
maxconn 2000
user haproxy
defaults
mode http
option redispatch