From d28777268f993b6e628666a48428398f1e78d8c1 Mon Sep 17 00:00:00 2001 From: Philip Durbin Date: Thu, 14 Sep 2017 16:00:48 -0400 Subject: [PATCH] stub out Docker and OpenShift files #4040 --- Dockerfile | 1 + conf/docker/build.sh | 2 + conf/docker/dataverse-glassfish/Dockerfile | 5 +++ conf/docker/postgresql/Dockerfile | 3 ++ conf/docker/solr/Dockerfile | 8 ++++ conf/openshift/openshift.json | 40 +++++++++++++++++++ .../source/installation/index.rst | 1 + .../source/installation/openshift.rst | 24 +++++++++++ .../source/installation/prep.rst | 5 +++ 9 files changed, 89 insertions(+) create mode 100644 Dockerfile create mode 100644 conf/docker/build.sh create mode 100644 conf/docker/dataverse-glassfish/Dockerfile create mode 100644 conf/docker/postgresql/Dockerfile create mode 100644 conf/docker/solr/Dockerfile create mode 100644 conf/openshift/openshift.json create mode 100644 doc/sphinx-guides/source/installation/openshift.rst diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000000..5f492ea0594 --- /dev/null +++ b/Dockerfile @@ -0,0 +1 @@ +# See `conf/docker` for Docker images diff --git a/conf/docker/build.sh b/conf/docker/build.sh new file mode 100644 index 00000000000..95a3a15979a --- /dev/null +++ b/conf/docker/build.sh @@ -0,0 +1,2 @@ +#!/bin/sh +echo "TODO: Build docker images and push to DockerHub." diff --git a/conf/docker/dataverse-glassfish/Dockerfile b/conf/docker/dataverse-glassfish/Dockerfile new file mode 100644 index 00000000000..603660b5264 --- /dev/null +++ b/conf/docker/dataverse-glassfish/Dockerfile @@ -0,0 +1,5 @@ +# Glassfish and Dataverse in one Docker image, as suggested by danmcp. +# +# TODO: Start with the Dataverse 4.2.3 version at https://github.com/pdurbin/ndslabs-dataverse/blob/v4.2.3.1/dockerfiles/dataverse/Dockerfile +# +# TODO: Once we get Dataverse 4.2.3 working, we can try Dataverse 4.7 from https://github.com/pdurbin/ndslabs-dataverse/blob/upgrade-4.7/dockerfiles/dataverse/Dockerfile diff --git a/conf/docker/postgresql/Dockerfile b/conf/docker/postgresql/Dockerfile new file mode 100644 index 00000000000..81ecf0fdeb8 --- /dev/null +++ b/conf/docker/postgresql/Dockerfile @@ -0,0 +1,3 @@ +# PostgreSQL for Dataverse (but consider switching to the image from CentOS) +# +# See also conf/docker/dataverse-glassfish/Dockerfile diff --git a/conf/docker/solr/Dockerfile b/conf/docker/solr/Dockerfile new file mode 100644 index 00000000000..7d4bf9292e2 --- /dev/null +++ b/conf/docker/solr/Dockerfile @@ -0,0 +1,8 @@ +# Solr for Dataverse +# +# See the note about Dataverse 4.2.3 vs. 4.7 at conf/docker/dataverse-glassfish/Dockerfile +# +# Note that there is a separate Dockerfile we can start with: +# +# Dataverse 4.2.3: https://github.com/pdurbin/ndslabs-dataverse/blob/v4.2.3.1/dockerfiles/solr/Dockerfile +# Dataverse 4.7: https://github.com/pdurbin/ndslabs-dataverse/blob/upgrade-4.7/dockerfiles/solr/Dockerfile diff --git a/conf/openshift/openshift.json b/conf/openshift/openshift.json new file mode 100644 index 00000000000..e1f92c0fbdb --- /dev/null +++ b/conf/openshift/openshift.json @@ -0,0 +1,40 @@ +{ + "kind": "Project", + "apiVersion": "v1", + "metadata": { + "name": "dataverse", + "creationTimestamp": null, + "labels": { + "name": "dataverse" + }, + "annotations": { + "openshift.io/description": "Dataverse is open source research data repository software: https://dataverse.org", + "openshift.io/display-name": "Dataverse" + } + }, + "spec": { + "containers": [ + { + "name": "dataverse-glassfish", + "image": "ndslabs/dataverse", + "ports": [ + { + "containerPort": 8080, + "protocol": "TCP" + } + ] + }, + { + "name": "dataverse-solr", + "image": "ndslabs/dataverse-solr", + "ports": [ + { + "containerPort": 8983, + "protocol": "TCP" + } + ] + } + ] + }, + "status": {} +} diff --git a/doc/sphinx-guides/source/installation/index.rst b/doc/sphinx-guides/source/installation/index.rst index b8423e77ae5..185fb94b4e3 100755 --- a/doc/sphinx-guides/source/installation/index.rst +++ b/doc/sphinx-guides/source/installation/index.rst @@ -20,3 +20,4 @@ Installation Guide geoconnect shibboleth oauth2 + openshift diff --git a/doc/sphinx-guides/source/installation/openshift.rst b/doc/sphinx-guides/source/installation/openshift.rst new file mode 100644 index 00000000000..71758cd23f9 --- /dev/null +++ b/doc/sphinx-guides/source/installation/openshift.rst @@ -0,0 +1,24 @@ +================================= +Installing Dataverse on OpenShift +================================= + +.. contents:: |toctitle| + :local: + +Familiarize Yourself with OpenShift +----------------------------------- + +https://docs.openshift.com/online/getting_started/index.html + +Create OpenShift Account +------------------------ + +Create Project +-------------- + +Import YAML/JSON +---------------- + +Upload ``conf/openshift/openshift.json``. + +FIXME: Getting "cannot create projects at the cluster scope" diff --git a/doc/sphinx-guides/source/installation/prep.rst b/doc/sphinx-guides/source/installation/prep.rst index 9662b5c40b6..ba8bf08cd4a 100644 --- a/doc/sphinx-guides/source/installation/prep.rst +++ b/doc/sphinx-guides/source/installation/prep.rst @@ -14,6 +14,11 @@ We'll try to get you up and running as quickly as possible, but we thought you m Choose Your Own Installation Adventure -------------------------------------- +OpenShift (for Testing Only) +++++++++++++++++++++++++++++ + +If you would like to kick the tires on your own installation of Dataverse, you can install it for free on OpenShift Online, a platform as a service (PaaS) offering from Red Hat. For details, please see the :doc:`openshift` section. + Vagrant (for Testing Only) ++++++++++++++++++++++++++