-
Notifications
You must be signed in to change notification settings - Fork 205
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added Dockerfiles for data backends.
- Loading branch information
k0105
committed
Jun 6, 2016
1 parent
e62d7cc
commit dc91ca3
Showing
3 changed files
with
75 additions
and
0 deletions.
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,38 @@ | ||
###################################### | ||
## DBpedia / Freebase Service Image ## | ||
###################################### | ||
|
||
# Proposed image name: dbpedia | ||
# Readme https://github.com/brmson/yodaqa/blob/master/data/dbpedia/ | ||
|
||
# Inherit official Java image, see https://hub.docker.com/_/java/ | ||
FROM java:8 | ||
|
||
# Copy fuseki files | ||
ADD ./jena-fuseki-1.1.1 /jena-fuseki-1.1.1 | ||
|
||
# Same as "export TERM=dumb"; prevents error "Could not open terminal for stdout: $TERM not set" | ||
ENV TERM dumb | ||
|
||
# Define working directory | ||
WORKDIR /jena-fuseki-1.1.1 | ||
|
||
# Expose ports (3030 for Freebase, 3037 for DBpedia) | ||
EXPOSE 3037 | ||
EXPOSE 3030 | ||
|
||
########## | ||
# BEWARE ##################################################################################### | ||
# With SELinux you need to run chcon -Rt svirt_sandbox_file_t /run/media/<user>/<longid>/home/<user>/Downloads/Backends/DBpedia/jena-fuseki-1.1.1/db/ | ||
############################################################################################## | ||
|
||
# Can be built with: "docker build -t fuseki ." | ||
|
||
# .:: DBpedia | ||
# docker run -it -v /home/fp/docker/data/db/:/jena-fuseki-1.1.1/db/ --entrypoint="./fuseki-server" -p 3037:3037 fuseki --port 3037 --loc db /dbpedia | ||
# RUN ./fuseki-server --port 3037 --loc db /dbpedia is done in run command; need to map as volume (read-only via :ro) | ||
|
||
# .:: Freebase | ||
# docker run -it -v /home/fp/docker/data/d-freebase/:/jena-fuseki-1.1.1/d-freebase/ --entrypoint="./fuseki-server" -p 3030:3030 fuseki --loc d-freebase /freebase | ||
# RUN ./fuseki-server --loc d-freebase /freebase | ||
|
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,36 @@ | ||
########################## | ||
## enwiki Service Image ## | ||
########################## | ||
|
||
# Proposed image name: enwiki | ||
# Readme https://github.com/brmson/yodaqa/tree/master/data/enwiki | ||
|
||
# Inherit official Java image, see https://hub.docker.com/_/java/ | ||
FROM java:8 | ||
|
||
# Copy fuseki files | ||
ADD ./solr-4.6.0 /solr-4.6.0 | ||
|
||
|
||
# JAVA_HOME is not set by default | ||
ENV JAVA_HOME /usr/lib/jvm/java-1.8.0-openjdk-amd64/ | ||
|
||
# Same as "export TERM=dumb"; prevents error "Could not open terminal for stdout: $TERM not set" | ||
ENV TERM dumb | ||
|
||
# Define working directory | ||
WORKDIR /solr-4.6.0/example | ||
|
||
# Expose port | ||
EXPOSE 8983 | ||
|
||
########## | ||
# BEWARE ##################################################################################### | ||
# With SELinux you need to run chcon -Rt svirt_sandbox_file_t /run/media/<user>/<longid>/home/<user>/Downloads/Backends/enwiki/solr-4.6.0/example/enwiki/collection1/ | ||
############################################################################################## | ||
|
||
# Can be built with: "docker build -t enwiki ." | ||
|
||
# docker run -it -v /run/media/<user>/<longid>/home/<user>/Downloads/Backends/enwiki/solr-4.6.0/example/enwiki/collection1/:/solr-4.6.0/example/enwiki/collection1/ --entrypoint="java" -p 8983:8983 enwiki -Dsolr.solr.home=enwiki -jar start.jar | ||
#docker run -it -v /home/fp/docker/data/enwiki/collection1/:/solr-4.6.0/example/enwiki/collection1/ --entrypoint="java" -p 8983:8983 enwiki -Dsolr.solr.home=enwiki -jar start.jar | ||
# RUN java -Dsolr.solr.home=enwiki -jar start.jar is done in run command; need to map as volume (read-only via :ro) |
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 @@ | ||
See ../dbpedia directory. The Fuseki image can be used for both DBpedia and Freebase depending on which volume is mapped. |