Skip to content

Commit

Permalink
stetl docker
Browse files Browse the repository at this point in the history
  • Loading branch information
justb4 committed Apr 21, 2016
1 parent 11c2fe1 commit ca3886c
Show file tree
Hide file tree
Showing 6 changed files with 190 additions and 0 deletions.
44 changes: 44 additions & 0 deletions docker/stetl/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
FROM ubuntu:14.04
# FROM python:2.7

MAINTAINER just@justobjects.nl

# Use local cached debs from host (saves your bandwidth!)
# Change ip below to that of your apt-cacher-ng host
# Or comment this line out if you do not with to use caching
# ADD 71-apt-cacher-ng /etc/apt/apt.conf.d/71-apt-cacher-ng
RUN export DEBIAN_FRONTEND=noninteractive TERM=linux && \
echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections

RUN apt-get -y update
RUN apt-get install -y software-properties-common
RUN apt-add-repository ppa:ubuntugis/ubuntugis-unstable
RUN apt-get -y update

#-------------Application Specific Stuff ----------------------------------------------------

# python-imaging \
# python-yaml \
# libjpeg-dev \
# zlib1g-dev \
# libfreetype6-dev \
# python-virtualenv

RUN apt-get install -y \
git \
libproj0 \
libgeos-dev \
python-lxml \
python-gdal \
libgdal-dev \
build-essential \
python-dev \
python-setuptools

# ADD start.sh /start.sh
# RUN chmod 0755 /start.sh
RUN git clone https://github.com/justb4/stetl /opt/stetl

RUN cd /opt/stetl; python setup.py install

ENTRYPOINT ["/usr/local/bin/stetl"]
15 changes: 15 additions & 0 deletions docker/stetl/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Stetl Docker

Docker image to run Stetl www.stetl.org commands.

## Building

docker build -t geonovum/stetl .

## Running

Mapping volumes can be handly to maintain all config and data outside the container.
Note that full paths are required.

cd test/1_copystd
docker run -v `pwd`:`pwd` -w `pwd` -t -i geonovum/stetl -c etl.cfg
5 changes: 5 additions & 0 deletions docker/stetl/start.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash

echo "Start script running, args=$1 $2"

ls $1
10 changes: 10 additions & 0 deletions services/config/api.smartemission.nl.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,20 @@
# WSGIApplicationGroup %{GLOBAL}
WSGIScriptAlias /sosemu /var/www/api.smartemission.nl/sosemu/index.py

WSGIScriptAlias /istsos /opt/istsos/latest/application.py
Alias /istsos/admin /opt/istsos/latest/interface/admin
Alias /istsos/modules /opt/istsos/latest/interface/modules

<Directory /var/www/api.smartemission.nl/sosemu/>
Require all granted
</Directory>

<LocationMatch /istsos>
Options +Indexes +FollowSymLinks +MultiViews
AllowOverride all
Require all granted
</LocationMatch>

# %D voor timing in microsecs
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-agent}i\" %D" mpcombined
CustomLog /var/log/apache2/api.smartem-access.log mpcombined
Expand Down
113 changes: 113 additions & 0 deletions services/istsos/default.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
[serviceType]
version = 1.0.0
codespace = http://opengeospatial.net
value = OGC:SOS

[getobservation]
correct_qi = 110
stat_qi = 200
aggregate_nodata_qi = -100
default_qi = 100
aggregate_nodata = -999.9
maxGoPeriod = 0
transactional_log = False

[serviceurl]
url =

[parameters]
GO_resultModel = om:Observation
DS_outputFormats = text/xml;subtype="sensorML/1.0.1"
GC_Section = serviceidentification,serviceprovider,operationsmetadata,contents,all
GO_responseFormat = text/xml;subtype="om/1.0.0",application/json,text/plain,text/xml,text/x-json
version = 1.0.0
GO_timeFormats = ISO 8601 (e.g.: 1997-12-17T07:37:16-08),xsi:type='TimeInstantType',xsi:type='TimePeriodType'
requests = getcapabilities,describesensor,getobservation,getfeatureofinterest,insertobservation,registersensor
GO_responseMode = inline

[urn]
identifier = urn:ogc:def:identifier:x-istsos:1.0:
offering = urn:ogc:def:offering:x-istsos:1.0:
parameter = urn:ogc:def:parameter:x-istsos:1.0:
phenomena = urn:ogc:def:phenomenon:x-istsos:1.0:
feature = urn:ogc:def:feature:x-istsos:1.0:
sensorType = urn:ogc:def:sensorType:x-istsos:1.0:
process = urn:ogc:def:process:x-istsos:1.0:
role = urn:role:x-istsos:1.0:
refsystem = urn:ogc:crs:EPSG:
keywords = urn:ogc:def:keywords:x-istsos:1.0:
time = urn:ogc:def:parameter:x-istsos:1.0:time:iso8601
dataType = urn:ogc:def:dataType:x-istsos:1.0:
property = urn:ogc:def:property:x-istsos:1.0:
sensor = urn:ogc:def:sensor:x-istsos:1.0:
procedure = urn:ogc:def:procedure:x-istsos:1.0:

[connection]
dbname = istsos
host = localhost
user = sensors
password = ******
port = 5432

[identification]
title = Smart Emission - Sensor Observation Service
abstract = monitoring network
urnversion = 1.0
authority = x-istsos
fees = NONE
keywords = SOS,SENSOR,NETWORK
accessConstrains = NONE

[foiGeometryType]
Box = surface
Polygon = surface
Point = station

[parGeom]
y = y-position,north,northing,lat,latitude,y
z = z-position,elevation,quota,z
x = x-position,east,easting,lon,longitude,x

[provider]
contactAdminArea = Utrecht
contactCountry = The Netherlands
providerName = Geonovum
contactCity = Amersfoort
contactVoice = +31334604100
contactEmail = info@geonovum.nl
contactDeliveryPoint = Barchman Wuytierslaan 10
contactName = Michel Grothe
contactPostalCode = 3818LH
contactPosition = Data manager
providerSite = http://geonovum.nl
contactFax = +31334604100

[geo]
zAxisName = altitude
xAxisName = easting
yAxisName = northing
allowedEPSG = 3857,21781,28992
istsosepsg = 4326

[initialization]
level = 42

[connectionWns]
dbname = istsos
host = 127.0.0.1
user = postgres
password = postgres
port = 5432

[mail]
smtp =
password =
usermail =
port =

[twitter]
oauth_secret =
consumer_secret =
oauth_token =
consumer_key =

3 changes: 3 additions & 0 deletions services/istsos/sound/sound.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[serviceurl]
url = http://api.smartemission.nl/istsos/sound

0 comments on commit ca3886c

Please sign in to comment.