Uploaded image for project: 'Bitbucket Data Center'
  1. Bitbucket Data Center
  2. BSERV-9194

Make Bitbucket Server Docker container configure external Elasticsearch instead of the bundled Elasticsearch

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Fixed
    • 5.0.0
    • None
    • We collect Bitbucket feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

    Description

      Since 4.6 the Docker image available from https://hub.docker.com/r/atlassian/bitbucket-server/ ends up starting both Bitbucket Server itself but additionally the bundled Elasticsearch instance.

      This is undesirable as it prevents the Docker image from being able to be used for production deployments (where only the actual instance should be running) and in particular for data center deployments as a local Elasticsearch will not be useful in that scenario. 

      https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/ contains:

      Run only one process per container

      In almost all cases, you should only run a single process in a single container. Decoupling applications into multiple containers makes it much easier to scale horizontally and reuse containers. If that service depends on another service, make use of container linking.

      Which pretty much sums this up.

      The advantage of the current situation is that search just works out of the box without any further configuration. 

      Instead of relying on the bundled instance we should either:

      • Document how to run and link a Bitbucket Server and the Elasticsearch container.
      • Provide a docker compose file that runs both correctly configured.

      This would re-enable the use of the Docker image for production deployments as it will avoid running another process inside the container.

      Other options that retain the current behaviour might include the usage of environment variables to enable/disable running the bundled Elasticsearch instance.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ssaasen Stefan Saasen (Inactive)
              Votes:
              2 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: