mirror of
https://github.com/farmOS/farmOS.git
synced 2024-02-23 11:37:38 +01:00
394daa9f06
By doing this, we will be forcing the end-user to follow best practice by making an intentional decision about the version they will use. We do not want farmos/farmos:2.x to be referenced by default in the docs, otherwise we will be directing folks to use the development branch, which may not be stable, and may change if they update the image via `docker pull`. We also don't want to recommend farmos/farmos:latest, for a similar reason: when updating between versions it is important to manually run update.php. By forcing intentional version use and updates, we encourage best practice for updates as well.
34 lines
1.5 KiB
Markdown
34 lines
1.5 KiB
Markdown
# Running farmOS with Docker
|
|
|
|
This directory contains files necessary to build the farmOS Docker image, along
|
|
with example `docker-compose.yml` files that can be used for running farmOS in
|
|
Docker containers.
|
|
|
|
## Development environment
|
|
|
|
To run a farmOS development environment, copy `docker-compose.development.yml`
|
|
into a new directory on your server, rename it to `docker-compose.yml` and run
|
|
`docker-compose up`.
|
|
|
|
This example mounts a local `www` directory on the host as a volume in the
|
|
container at `/opt/drupal`, which allows for local development with an IDE.
|
|
|
|
## Production environment
|
|
|
|
To run a farmOS production environment, use `docker-compose.production.yml` as
|
|
an example for building your own configuration. It references a non-existent
|
|
`farmos/farmos:x.y.z` image version tag, which should be replaced with the most
|
|
recent farmOS stable release version.
|
|
|
|
This example mounts a local `sites` directory on the host as a volume in the
|
|
container at `/opt/drupal/web/sites`, which contains the site-specific settings
|
|
and uploaded files. This allows a production farmOS instance to be updated by
|
|
simply pulling a new image (and then manually running database updates via Drush
|
|
or `/update.php`). Everything outside of the `sites` directory will not be
|
|
preserved and will be replaced with the new official farmOS files.
|
|
|
|
Note that this example does not include a database. It is assumed that in
|
|
production environments the database will be managed outside of Docker.
|
|
|
|
For more information, see https://farmOS.org/hosting.
|