summaryrefslogtreecommitdiffstats
path: root/extra
diff options
context:
space:
mode:
Diffstat (limited to 'extra')
-rw-r--r--extra/docker/README.md2
-rw-r--r--extra/docker/docker-compose.yml2
-rw-r--r--extra/elasticsearch/Dockerfile9
-rw-r--r--extra/elasticsearch/README.md3
-rw-r--r--extra/elasticsearch/release_schema.no-plugins.json42
5 files changed, 11 insertions, 47 deletions
diff --git a/extra/docker/README.md b/extra/docker/README.md
index 06ff06e1..4fd78e56 100644
--- a/extra/docker/README.md
+++ b/extra/docker/README.md
@@ -4,8 +4,6 @@ install some large dependencies. Currently it isn't *required* for core
development (the fatcat API server and most of the web interface), and also
doesn't bundle *all* dependencies.
-This requires
-
To start docker compose (kafka, zookeeper, elasticsearch) with logging in the
current terminal:
diff --git a/extra/docker/docker-compose.yml b/extra/docker/docker-compose.yml
index bfc2eb3e..85d98ec2 100644
--- a/extra/docker/docker-compose.yml
+++ b/extra/docker/docker-compose.yml
@@ -18,7 +18,7 @@ services:
volumes:
- /var/run/docker.sock:/var/run/docker.sock
elasticsearch:
- image: docker.elastic.co/elasticsearch/elasticsearch:6.4.2
+ build: ../elasticsearch/
ports:
- "9200:9200"
- "9300:9300"
diff --git a/extra/elasticsearch/Dockerfile b/extra/elasticsearch/Dockerfile
new file mode 100644
index 00000000..13d641a4
--- /dev/null
+++ b/extra/elasticsearch/Dockerfile
@@ -0,0 +1,9 @@
+FROM docker.elastic.co/elasticsearch/elasticsearch:6.4.2
+
+RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch analysis-icu
+
+# This part doesn't work because elastic isn't actually running at this point
+# in boot. Don't know enough Docker to figure out how to make this work at
+# build time.
+#COPY --chown=elasticsearch:elasticsearch release_schema.json /release_schema.json
+#RUN curl http://127.0.0.1:9200/fatcat --upload-file /release_schema.json
diff --git a/extra/elasticsearch/README.md b/extra/elasticsearch/README.md
index d5ac0c53..420f119b 100644
--- a/extra/elasticsearch/README.md
+++ b/extra/elasticsearch/README.md
@@ -32,8 +32,7 @@ We use elasticsearch version 6.x, with the `analysis-icu` plugin installed:
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin install analysis-icu
sudo service elasticsearch restart
-If you can't install this plugin easily (eg, in a docker container), you can
-use the `no-plugin` variant (though, warning, it might not be up to date).
+There is a Dockerfile in this directory which includes this installation.
## Loading Data
diff --git a/extra/elasticsearch/release_schema.no-plugins.json b/extra/elasticsearch/release_schema.no-plugins.json
deleted file mode 100644
index c879c176..00000000
--- a/extra/elasticsearch/release_schema.no-plugins.json
+++ /dev/null
@@ -1,42 +0,0 @@
-{
-"mappings": {
- "release": {
- "properties": {
- "ident": { "type": "keyword" },
- "revision": { "type": "keyword" },
- "title": { "type": "text", "index": true },
- "author": { "type": "alias", "path": "contrib_names" },
- "journal": { "type": "alias", "path": "container_name" },
- "date": { "type": "alias", "path": "release_date" },
- "issn": { "type": "alias", "path": "container_issnl" },
- "oa": { "type": "alias", "path": "container_is_oa" },
- "longtail": { "type": "alias", "path": "container_is_longtail_oa" },
- "release_date": { "type": "date" },
- "release_type": { "type": "keyword" },
- "release_status": { "type": "keyword" },
- "language": { "type": "keyword" },
- "doi": { "type": "keyword" },
- "pmid": { "type": "keyword" },
- "pmcid": { "type": "keyword" },
- "isbn13": { "type": "keyword" },
- "core_id": { "type": "keyword" },
- "wikidata_qid": { "type": "keyword" },
- "publisher": { "type": "text", "index": true },
- "container_name": { "type": "text", "index": true },
- "container_issnl": { "type": "keyword" },
- "container_is_oa": { "type": "boolean" },
- "container_is_longtail_oa": { "type": "boolean" },
- "contrib_count": { "type": "integer" },
- "contrib_names": { "type": "text", "index": true },
- "ref_count": { "type": "integer" },
- "file_count": { "type": "integer" },
- "file_pdf_url": { "type": "keyword" },
- "file_in_webarchive": { "type": "boolean" },
- "file_in_ia": { "type": "boolean" },
- "any_abstract": { "type": "boolean" },
- "is_kept": { "type": "boolean" },
- "in_shadow": { "type": "boolean" }
- }
- }
-}
-}