How-to for Bitbucket Mirror in Docker container

This question is in reference to the docker Bitbucket server project here: .  I'm running in "mirror mode" like this "APPLICATION_MODE=mirror" via a docker-compose environment setting.

By default, the container exposes ports 7990 and 7999 (http and ssh).  No mention of https.  When running as a mirror, however, https and a valid ssl cert is a firm requirement.

How do I configure the container to support https?

I'm using the current latest version (5.5.0).

Thanks for any help or tips.

2 answers

1 accepted

0 vote

Hi Trask,

Those settings are controlled in the file (see Bitbucket Server configuration properties for details), but the good news is that they are also exposed via environment variables.

For instance server.ssl.enabled=true becomes SERVER_SSL_ENABLED=true, likewise server.ssl.key-store becomes SERVER_SSL_KEY_STORE, etc.



Premier Support Engineer


Thanks Christian.  That lead me down the right path.  Below is my [redacted] {{docker-compose.yml}} file that might help others in the future.

I dug through a lot of documentation and wasn't aware that this was a way to accomplish setting up https-enabled mirror via docker.


Example for a BitBucket server in Mirror mode


version: '2'
    restart: always
    image: atlassian/bitbucket-server:5.5.0
      - ""
      - ""
      - "/media/RAID/bitbucket/bitbucket-server:/var/atlassian/application-data/bitbucket"
      - APPLICATION_MODE=mirror
      - SERVER_SECURE=true
      - SERVER_SSL_KEY_ALIAS=tomcat
      - SERVER_SSL_KEY_STORE=/var/atlassian/application-data/bitbucket/shared/config/ssl-keystore

I should mention I have valid certs and can handle the certificate configuration once I find out how to configure https support in the built-in http server.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

22,544 views 26 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you