aboutsummaryrefslogtreecommitdiffstats
path: root/docs/install
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2018-09-27 17:16:44 +0100
committerSam Pearson <sam@sgp.me.uk>2018-09-28 14:37:04 +0100
commit7149fb72f685d4950835d25c045ce96b13ef496f (patch)
tree5fbc8df921628c6dfef394d18a619345a39b4473 /docs/install
parentd5aeacbfeca3b9f07ff846dcb6f877ac4e59095f (diff)
[Docs] Initial documentation for Docker installations
This adds details of our Docker images and the example Docker Compose environment, including notes on how to use this with a cobrand and how to customise the database configuration.
Diffstat (limited to 'docs/install')
-rw-r--r--docs/install/ami.md2
-rw-r--r--docs/install/docker.md91
-rw-r--r--docs/install/index.md8
-rw-r--r--docs/install/install-script.md2
-rw-r--r--docs/install/manual-install.md2
-rw-r--r--docs/install/troubleshooting.md2
-rw-r--r--docs/install/vagrant.md2
7 files changed, 100 insertions, 9 deletions
diff --git a/docs/install/ami.md b/docs/install/ami.md
index 783c23727..5f6df3af4 100644
--- a/docs/install/ami.md
+++ b/docs/install/ami.md
@@ -12,7 +12,7 @@ title: AMI for EC2
EC2 instance.
</p>
-Note that this is just one of [four ways to install FixMyStreet]({{ "/install/" | relative_url }}).
+Note that this is just one of [many ways to install FixMyStreet]({{ "/install/" | relative_url }}).
## Installing on Amazon's Web Services
diff --git a/docs/install/docker.md b/docs/install/docker.md
new file mode 100644
index 000000000..3c716a5da
--- /dev/null
+++ b/docs/install/docker.md
@@ -0,0 +1,91 @@
+---
+layout: page
+title: Docker
+---
+
+# FixMyStreet with Docker
+
+<p class="lead">
+ You can use Docker and Docker Compose to get up and running quickly
+ with FixMyStreet.
+</p>
+
+This is just one of [many ways to install FixMyStreet]({{ "/install/" | relative_url }}).
+
+## Public images
+
+As well as providing a `Dockerfile` which you could use as the basis of your own
+customised build, we provide public [images on Docker Hub](https://hub.docker.com/u/fixmystreet/)
+with a full FixMyStreet installation for each of our tagged releases.
+
+## Docker Compose
+
+If you have Docker and Docker Compose installed, then the following should
+set up a working FixMyStreet installation, with containers for the application,
+database, memcached and webserver:
+
+ docker-compose up
+
+You can then layer your own [cobrand-specific code](/customising/)
+on top, update the configuration, or log in and make changes.
+
+A superuser is automatically created, with email `superuser@example.org`
+and password given in `docker-compose.yml`.
+
+This basic installation uses the default cobrand, with a
+(deliberately) rather garish colour scheme.
+
+## Adding your own cobrand
+
+If you want to map your own cobrand data into the Docker container, have a
+repository/directory that contains the following (all items optional):
+
+ my-cobrand-repo/
+ templates/web/(cobrand)/
+ templates/email/(cobrand)/
+ perllib/FixMyStreet/Cobrand/(CoBrand.pm)
+ web/cobrands/(cobrand)/
+
+Create a docker-compose.override.yml file containing:
+
+ version: '3'
+
+ services:
+ fixmystreet:
+ volumes:
+ - /path/to/your/general.yml:/var/www/fixmystreet/fixmystreet/conf/general.yml
+ - /path/to/my-cobrand-repo:/var/www/fixmystreet/cobrand
+
+Now if you run `docker-compose up` it should automatically include that cobrand
+within the running container.
+
+This is a new facility, so please do feed back your thoughts.
+
+## Database configuration
+
+The example Docker Compose environment includes a [slightly customised Postgres container](https://github.com/mysociety/public-builds/tree/master/docker/postgres)
+based on [the official image](https://hub.docker.com/_/postgres/) and localised for `en_GB`.
+
+This will be configured the first time it is started and its data stored in a
+Docker volume for persistence. The password for the `postgres` user should be set
+in the `POSTGRES_PASSWORD` environment variable and made available to both the
+database and application containers; along with the various `FMS_DB_*` environment
+variables this will be used to ensure the correct users, permissions and databases
+are created when the container starts for the first time.
+
+### Using an external database
+
+If you wish to host the database in an external service you can do so by updating
+the various `FMS_DB_*` environment variables used by the application container and
+in `general.yml`. You should not provide a `POSTGRES_PASSWORD` variable to the
+application container in this case.
+
+The application container will attempt to create the database if it doesn't already exist, so
+you can either provide the user with the `CREATEDB` privilege or simply provide
+an empty database and the application container will load the schema when it starts
+for the first time.
+
+## Installation complete... now customise
+
+You should then proceed
+to [customise your installation](/customising/).
diff --git a/docs/install/index.md b/docs/install/index.md
index ebd4a8d7e..22abb263d 100644
--- a/docs/install/index.md
+++ b/docs/install/index.md
@@ -6,13 +6,13 @@ title: Installing
# Installing FixMyStreet Platform
<p class="lead">
- There are several options for installing the FixMyStreet platform. Unless
- you're confident deploying web applications, we recommend you use the
- installation script or the AMI for Amazon EC2.
+ There are several options for installing the FixMyStreet platform,
+ including Docker, an AMI for Amazon EC2 or an installation script.
</p>
-## Four ways to install
+## Ways to install
+* [Use Docker]({{ "/install/docker/" | relative_url }})
* [Use an install script for Debian or Ubuntu servers]({{ "/install/install-script/" | relative_url }})
* [Use a FixMyStreet AMI for Amazon EC2]({{ "/install/ami/" | relative_url }})
* [Vagrant installation]({{ "/install/vagrant/" | relative_url }}), for development
diff --git a/docs/install/install-script.md b/docs/install/install-script.md
index ba2c2bef8..124434b34 100644
--- a/docs/install/install-script.md
+++ b/docs/install/install-script.md
@@ -11,7 +11,7 @@ title: Install script
FixMyStreet on your server.
</p>
-Note that this is just one of [four ways to install FixMyStreet]({{ "/install/" | relative_url }}).
+Note that this is just one of [many ways to install FixMyStreet]({{ "/install/" | relative_url }}).
## Warning: installation changes your setup!
diff --git a/docs/install/manual-install.md b/docs/install/manual-install.md
index 45522fd4e..8acccdddf 100644
--- a/docs/install/manual-install.md
+++ b/docs/install/manual-install.md
@@ -11,7 +11,7 @@ title: Installing
but the other installation options may be easier:</p>
Note that this is just one of
-[four ways to install FixMyStreet]({{ "/install/" | relative_url }})
+[many ways to install FixMyStreet]({{ "/install/" | relative_url }})
(the other ways are easier!).
diff --git a/docs/install/troubleshooting.md b/docs/install/troubleshooting.md
index 2b49cb616..b006d18a4 100644
--- a/docs/install/troubleshooting.md
+++ b/docs/install/troubleshooting.md
@@ -6,7 +6,7 @@ title: Installation troubleshooting
# Installation troubleshooting
<p class="lead">
- If you've installed FixMyStreet using the
+ If you've installed FixMyStreet using an automated method such as the
<a href="{{ "/install/install-script" | relative_url }}">installation script</a>
or the
<a href="{{ "/install/ami" | relative_url }}">AMI</a>, you should be good to go.
diff --git a/docs/install/vagrant.md b/docs/install/vagrant.md
index 0b9cd8812..98f846644 100644
--- a/docs/install/vagrant.md
+++ b/docs/install/vagrant.md
@@ -12,7 +12,7 @@ We bundle an example Vagrantfile in the repository, which runs the
<a href="{{ "/install/install-script/" | relative_url }}">install script</a> for you.
</p>
-Note that this is just one of [four ways to install FixMyStreet]({{ "/install/" | relative_url }}).
+Note that this is just one of [many ways to install FixMyStreet]({{ "/install/" | relative_url }}).
<div class="attention-box warning">
Vagrant is only suitable for use as a