-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into feature/cacheformat
- Loading branch information
Showing
6 changed files
with
180 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
FROM ubuntu:14.04 | ||
|
||
MAINTAINER Dmitry Pokidov <dooman87@gmail.com> | ||
|
||
WORKDIR / | ||
|
||
ENV GO15VENDOREXPERIMENT=0 | ||
ENV PATH=/opt/go/bin:/gohome/bin:$PATH | ||
ENV GOPATH=/gohome | ||
ENV GOROOT=/opt/go | ||
|
||
RUN apt-get update && \ | ||
apt-get -y install automake bison flex g++ git libboost1.54-all-dev libevent-dev libssl-dev libtool make \ | ||
pkg-config wget \ | ||
python-mapnik libmapnik-dev \ | ||
protobuf-compiler libprotobuf-dev \ | ||
jq cmake libncurses5-dev && \ | ||
rm -rf /var/lib/apt/lists/* | ||
|
||
#Installing apache thrift | ||
RUN wget http://apache.uberglobalmirror.com/thrift/0.9.3/thrift-0.9.3.tar.gz && \ | ||
tar -xzvf thrift-0.9.3.tar.gz && \ | ||
rm ./thrift-0.9.3.tar.gz && \ | ||
cd /thrift-0.9.3 && \ | ||
./configure --without-java && \ | ||
make && \ | ||
make install | ||
|
||
#Install golang 1.6 | ||
WORKDIR /opt | ||
RUN wget https://storage.googleapis.com/golang/go1.6.linux-amd64.tar.gz && \ | ||
tar -xzvf go1.6.linux-amd64.tar.gz && \ | ||
rm go1.6.linux-amd64.tar.gz && \ | ||
mkdir -p /gohome/bin && \ | ||
mkdir -p /gohome/pkg && \ | ||
mkdir /gohome/src | ||
|
||
RUN go get github.com/mattn/gom | ||
|
||
RUN mkdir /gopnik | ||
ADD . /gopnik | ||
WORKDIR /gopnik | ||
RUN gom install && \ | ||
gom exec ./bootstrap.bash && \ | ||
gom exec ./build.bash | ||
|
||
RUN mkdir /gopnik_data | ||
COPY example/dockerconfig.json /gopnik_data/config.json | ||
COPY sampledata/stylesheet.xml /gopnik_data/ | ||
COPY sampledata/world_merc.shp /gopnik_data/ | ||
COPY sampledata/world_merc.dbf /gopnik_data/ | ||
VOLUME /gopnik_data | ||
|
||
EXPOSE 8080 | ||
EXPOSE 9090 | ||
|
||
ENTRYPOINT ./entrypoint.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
gom 'github.com/cheggaaa/pb', :commit => '8808370bf63524e115da1371ba42bce6739f3a6b' | ||
gom 'github.com/davecgh/go-spew/spew', :commit => '5215b55f46b2b919f50a1df0eaa5886afe4e3b3d' | ||
gom 'github.com/golang/protobuf/proto', :commit => 'dda510ac0fd43b39770f22ac6260eb91d377bce3' | ||
gom 'github.com/golang/protobuf/protoc-gen-go', :commit => 'dda510ac0fd43b39770f22ac6260eb91d377bce3' | ||
gom 'github.com/go-martini/martini', :commit => 'b174c4f35f9f3805e960be6286d888bc79534755' | ||
gom 'github.com/martini-contrib/staticbin', :commit => 'b9631fb8c188bec7aefed202f05fb3b76abadced' | ||
gom 'github.com/op/go-logging', :commit => '970db520ece77730c7e4724c61121037378659d9' | ||
gom 'github.com/orofarne/hmetrics2', :commit => '006bcad088fa29b689daa57700c58094d1031664' | ||
gom 'github.com/orofarne/hmetrics2-graphite', :commit => '9888dcbe67c94e48fa715ff4d3e18ae5b7549abd' | ||
gom 'github.com/stretchr/testify/assert', :commit => '0744955171b0b6e1871ff9d7366abc2b7a7fcec0' | ||
gom 'github.com/stretchr/testify/require', :commit => '0744955171b0b6e1871ff9d7366abc2b7a7fcec0' | ||
gom 'github.com/yosssi/rendergold', :commit => '5cd20c624fd531597e1a6566196d7dd6ff342ae2' | ||
gom 'github.com/orofarne/strict-json', :commit => 'e220748385bad49f5bf127fa5521559723f48a4c' | ||
gom 'github.com/orofarne/freetype-go/freetype', :commit => '066003d5bbffa8f5927858a65bec052b312a3792' | ||
gom 'github.com/jteeuwen/go-bindata/go-bindata', :commit => 'a0ff2567cfb70903282db057e799fd826784d41d' | ||
gom 'git.apache.org/thrift.git/lib/go/thrift', :commit => '3aa461b97b3230d357543808f1facf9898818f71' | ||
gom 'gopkg.in/check.v1', :commit => '4f90aeace3a26ad7021961c297b22c42160c7b25' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
|
||
cd /gopnik/bin | ||
./gopnikrender --config /gopnik_data/config.json & | ||
./gopnikdispatcher --config /gopnik_data/config.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
{ | ||
"Dispatcher": { | ||
"Addr": ":8080", | ||
"HTTPReadTimeout": "60s", | ||
"HTTPWriteTimeout": "60s", | ||
"RequestTimeout": "600s", | ||
"PingPeriod": "30s", | ||
"Threads": -1, | ||
"Logging": { | ||
"Backend": "Console", | ||
"Level": "Debug", | ||
"Options": { | ||
"Color": true | ||
} | ||
}, | ||
"ClusterPlugin": { | ||
"Plugin": "ClusterConfigPlugin", | ||
"PluginConfig": { | ||
"Nodes": ["localhost:8090"] | ||
} | ||
} | ||
}, | ||
"Render": { | ||
"Addr": ":8090", | ||
"DebugAddr": ":9090", | ||
"Logging": { | ||
"Backend": "Console", | ||
"Level": "Debug", | ||
"Options": { | ||
"Color": true | ||
} | ||
} | ||
}, | ||
"Prerender": { | ||
"UIAddr": ":8088", | ||
"PerfLog": "/tmp/prerender.perf", | ||
"Logging": { | ||
"Backend": "Console", | ||
"Level": "Debug", | ||
"Options": { | ||
"Color": false | ||
} | ||
}, | ||
"Slaves": { | ||
"Plugin": "ClusterConfigPlugin", | ||
"PluginConfig": { | ||
"Nodes": ["localhost:8095"] | ||
} | ||
} | ||
}, | ||
"PrerenderSlave": { | ||
"RPCAddr": ":8095", | ||
"Logging": { | ||
"Backend": "Console", | ||
"Level": "Debug", | ||
"Options": { | ||
"Color": false | ||
} | ||
} | ||
}, | ||
"MetaSize": 8, | ||
"TileSize": 256, | ||
|
||
"CachePlugin": { | ||
"Plugin": "SimpleFileCachePlugin", | ||
"PluginConfig": { | ||
"Root": "/tmp/tiles" | ||
} | ||
}, | ||
"RenderPools": [ | ||
{ | ||
"Cmd": ["/gopnik/bin/gopnikslave", "-stylesheet", "/gopnik_data/stylesheet.xml", "-pluginsPath", "/usr/lib/mapnik/2.2/input"], | ||
"MinZoom": 1, | ||
"MaxZoom": 8, | ||
"PoolSize": 1, | ||
"HPQueueSize": 100, | ||
"LPQueueSize": 100, | ||
"RenderTTL": 10 | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters