From c96595639ce35998bfc25e2a871750c9575fba54 Mon Sep 17 00:00:00 2001 From: Babibubebon Date: Tue, 1 Sep 2020 03:55:31 +0900 Subject: [PATCH] Update README.md --- README.md | 48 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ceabed0..5e4f422 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,57 @@ lodfe ===== -SPARQLエンドポイントを用いたLinked Open Dataフロントエンド([Pubby](https://github.com/cygri/pubby)みたいなやつ) +SPARQLエンドポイントを用いたLinked Open Dataフロントエンド( [Pubby](https://github.com/cygri/pubby) みたいなやつ) ## Installation +### From source ``` $ git clone https://github.com/Babibubebon/lodfe.git $ cd lodfe $ composer install $ cp config/datasets.php{.example,} ``` + +And configure your Web server. + +### Docker image +Create `docker-compose.yml` +``` +version: "3" +services: + php: + image: babibubebon/lodfe:latest-php + volumes: + - ./datasets.php:/var/www/lodfe/config/datasets.php:ro + + nginx: + image: babibubebon/lodfe:latest-nginx + ports: + - 80:80 + depends_on: + - php +``` + +Create `datasets.php` like the below example: +``` + [ + 'host_name' => 'localhost', + 'resource_uri' => 'http://ja.dbpedia.org/resource/{id}', + 'html_uri' => 'http://ja.dbpedia.org/page/{id}', + 'data_uri' => 'http://ja.dbpedia.org/data/{id}', + 'endpoint' => 'http://ja.dbpedia.org/sparql', + 'http' => [ + 'timeout' => 30, + ] + ], +]; +``` + +Launch the containers +``` +$ docker-compose up -d +``` + +Open browser and goto http://localhost/resource/WHITE_ALBUM2