docker container and docker-compose file for gitbucket

data/ conf add mysql config 5 years ago
docker update version 5 years ago
.env inital commit 5 years ago
.gitignore ignore data and gist dir 5 years ago add license 5 years ago add build state 5 years ago fix mysql backup 5 years ago
docker-compose.yml switch do mariadb and check health state 5 years ago add script to change database passwords 5 years ago
gitbucket.conf different bind address for web and ssh 5 years ago add user id update script 5 years ago
version add version file 5 years ago

docker container for gitbucket

Build Status

This docker container of gitbucket is in beta state!

Table of contents




  1. Get code from repository:

    git clone
    cd gitbucket
  2. Generate new passwords for your databse!!!

  3. Get latest container:

    docker-compose pull
  4. Change the confoguration and start with:

    docker-compose up -d
  5. Open and be habby. :-) Default user and passwort are both root.


Please use the configuration file gitbucket.conf for your personal changes. There are three configs for gitbucket:

  • GITBUCKET_BIND: ip address to bind to
  • GITBUCKET_WEB_PORT: web port to bind to
  • GITBUCKET_SSH_PORT: ssh port to bind to


Update your gitbucket image in three steps. But first of all: MAKE A BACKUP!!!

  1. Commit your local changes. Changes in gitbucket.conf will be ignored!

  2. get the new image Shutdown and remove your images. This will not delete your mysql database volume.

    docker-compose down

    After that get the new image and start it:

    docker-compose pull
    docker-compose up -d --remove-orphans
  3. cleanup your docker environment This step is optional. Please do this only if you understand the next line.

    docker rmi -f $(docker images -f "dangling=true" -q)


To use plugins download the plugin and move it into data/plugins. After that restart the gitbucket container with docker-compose restart main-gitbucket.


For backuping the mysql database and the repositories you could use the script and combine it with a daily cronjob. This script will create a compressed backup and keep the files 10 days in the backup directory. All files which are older then 10 days will be deleted.


Error 503 on first start

Please check the gitbucket log files with

docker-compose logs main-gitbucket

If you get Could not connect to address=(host= as error: Please restart the gitbucket container with docker-compose restart main-gitbucket because the mariadb container needs some time to run completly at the first start. After that it should be work. If doesn't please contact me via because gitbucket does not allow issues for guests.

Contact and Contribution

You can write me an email ( ) or you could register here as an user to contribute to this project. After register please fork this repository and create pull reqeusts with your changes or add an issue.


  • check gitbucket.war hash after download
  • maybe a nginx container with ssl???


I got some inspirations for this project from:


cc-bc-sa: Please see license

Gitbucket license