Public | Automated Build

Last pushed: 11 hours ago
Short Description
GitLab Community Edition docker image based on the Omnibus package
Full Description

GitLab Docker images

Docker Pull Command
Owner
gitlab
Source Repository

Comments (94)
jeffersfp
11 hours ago

I just wanna share that yesterday (April 25) I did upgrade my company's Gitlab CE from 8.17.3 to 9.1.0 and it worked like a charm! Gitlab + Docker = <3

combiner
5 days ago

WTF?!

No source of timezone data could be found.
apt-get install -y tzdata
unable to make backup link of './usr/share/zoneinfo/Etc/UTC' before installing new version: Invalid cross-device link
E: Sub-process /usr/bin/dpkg returned an error code (1)

archite
5 days ago

tzdata package is missing causing chef to fail. Installing it allows gitlab-ctl reconfigure to succeed.

marcelhuberfoo
5 days ago

Upgrade to 9.0.6-ce.0 FAILS, I would recommend not using it!
(At least if upgrading from an older version like 9.0.5-ce.0)

hex6ng
8 days ago

Does anyone has experience upgrading from 8.12.7 to 9.0.5? Do you know how long such an upgrade typically takes? I'm following this guide to do the upgrade but it has been running for 3 hours now and there isn't any sign of progress. The docker container logs seems to be cycling on the same messages over and over:

....
==> /var/log/gitlab/redis/current <==
2017-04-18_17:42:31.02240 372:M 18 Apr 17:42:31.022 * 10000 changes in 60 seconds. Saving...
2017-04-18_17:42:31.02242 372:M 18 Apr 17:42:31.022 * Background saving started by pid 18271
2017-04-18_17:42:31.02840 18271:C 18 Apr 17:42:31.028 * DB saved on disk
2017-04-18_17:42:31.02873 18271:C 18 Apr 17:42:31.028 * RDB: 0 MB of memory used by copy-on-write
2017-04-18_17:42:31.12254 372:M 18 Apr 17:42:31.122 * Background saving terminated with success

==> /var/log/gitlab/gitlab-monitor/current <==
2017-04-18_17:42:31.15162 ::1 - - [18/Apr/2017:17:42:31 UTC] "GET /sidekiq HTTP/1.1" 200 3135
2017-04-18_17:42:31.15173 - -> /sidekiq
2017-04-18_17:42:33.06104 ::1 - - [18/Apr/2017:17:42:33 UTC] "GET /database HTTP/1.1" 200 33607
2017-04-18_17:42:33.06117 - -> /database

==> /var/log/gitlab/node-exporter/current <==
2017-04-18_17:42:34.53559 time="2017-04-18T17:42:34Z" level=error msg="ERROR: hwmon collector failed after 0.000014s: open /sys/class/hwmon: no such file or directory" source="node_exporter.go:91"

==> /var/log/gitlab/gitlab-monitor/current <==
2017-04-18_17:42:35.33889 ::1 - - [18/Apr/2017:17:42:35 UTC] "GET /process HTTP/1.1" 200 1158
2017-04-18_17:42:35.33891 - -> /process
2017-04-18_17:42:46.15229 ::1 - - [18/Apr/2017:17:42:46 UTC] "GET /sidekiq HTTP/1.1" 200 3135
2017-04-18_17:42:46.15243 - -> /sidekiq
2017-04-18_17:42:48.06290 ::1 - - [18/Apr/2017:17:42:48 UTC] "GET /database HTTP/1.1" 200 33607
2017-04-18_17:42:48.06303 - -> /database

==> /var/log/gitlab/node-exporter/current <==
2017-04-18_17:42:49.53555 time="2017-04-18T17:42:49Z" level=error msg="ERROR: hwmon collector failed after 0.000012s: open /sys/class/hwmon: no such file or directory" source="node_exporter.go:91"

==> /var/log/gitlab/gitlab-monitor/current <==
2017-04-18_17:42:50.33682 ::1 - - [18/Apr/2017:17:42:50 UTC] "GET /process HTTP/1.1" 200 1158
2017-04-18_17:42:50.33684 - -> /process
2017-04-18_17:43:01.15220 ::1 - - [18/Apr/2017:17:43:01 UTC] "GET /sidekiq HTTP/1.1" 200 3135
2017-04-18_17:43:01.15240 - -> /sidekiq
2017-04-18_17:43:03.06055 ::1 - - [18/Apr/2017:17:43:03 UTC] "GET /database HTTP/1.1" 200 33607
2017-04-18_17:43:03.06086 - -> /database

==> /var/log/gitlab/node-exporter/current <==
2017-04-18_17:43:04.53819 time="2017-04-18T17:43:04Z" level=error msg="ERROR: hwmon collector failed after 0.000013s: open /sys/class/hwmon: no such file or directory" source="node_exporter.go:91"

==> /var/log/gitlab/gitlab-monitor/current <==
2017-04-18_17:43:05.33673 ::1 - - [18/Apr/2017:17:43:05 UTC] "GET /process HTTP/1.1" 200 1158
2017-04-18_17:43:05.33675 - -> /process

==> /var/log/gitlab/gitlab-rails/production.log <==
Started GET "/help" for 127.0.0.1 at 2017-04-18 17:43:10 +0000
Processing by HelpController#index as */*
Completed 200 OK in 52ms (Views: 38.0ms | ActiveRecord: 2.1ms)

==> /var/log/gitlab/gitlab-workhorse/current <==
2017-04-18_17:43:10.55179 localhost @ - - [2017-04-18 17:43:10.494048047 +0000 UTC] "GET /help HTTP/1.1" 200 18654 "" "curl/7.53.0" 0.057685

==> /var/log/gitlab/nginx/gitlab_access.log <==
127.0.0.1 - - [18/Apr/2017:17:43:10 +0000] "GET /help HTTP/1.1" 200 18682 "-" "curl/7.53.0"
...
dco1
12 days ago

In /var/log/gitlab/unicorn/unicorn_stderr.log I'm seeing:

ArgumentError: Already running on PID:428 (or pid=/opt/gitlab/var/unicorn/unicorn.pid is stale)                       |gitlab_1             | ==> /var/log/gitlab/unicorn/current <==
  /opt/gitlab/embedded/lib/ruby/gems/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:195:in `pid='                |gitlab_1             | 2017-04-14_16:20:26.42584 master failed to start, check stderr log for details
  /opt/gitlab/embedded/lib/ruby/gems/2.3.0/gems/unicorn-5.1.0/lib/unicorn/http_server.rb:127:in `start'               |  C-c C-cGracefully stopping... (press Ctrl+C again to force)
  /opt/gitlab/embedded/lib/ruby/gems/2.3.0/gems/unicorn-5.1.0/bin/unicorn:126:in `<top (required)>'                   |Stopping ansible_shell_1 ...
  /opt/gitlab/embedded/bin/unicorn:22:in `load'                                                                       |Stopping ansible_subgit_1 ...
  /opt/gitlab/embedded/bin/unicorn:22:in `<top (required)>'

I'm also having difficulty getting this container to work. I had it working not long ago...

gaetanquentin
13 days ago

nothing works. gitlab isn't listening on 80 neither 443 port in the container.

tcp 0 0 127.0.0.1:9100 0.0.0.0: LISTEN
tcp 0 0 127.0.0.1:9168 0.0.0.0:
LISTEN
tcp 0 0 127.0.0.1:8080 0.0.0.0: LISTEN
tcp 0 0 0.0.0.0:22 0.0.0.0:
LISTEN
tcp 0 0 127.0.0.1:9121 0.0.0.0: LISTEN
tcp 0 0 127.0.0.1:8065 0.0.0.0:
LISTEN
tcp 0 0 127.0.0.1:9090 0.0.0.0: LISTEN
tcp 0 0 127.0.0.1:9187 0.0.0.0:
LISTEN
tcp 0 0 127.0.0.1:9090 127.0.0.1:48768 TIME_WAIT
tcp 0 0 172.20.10.3:57016 54.153.54.194:443 TIME_WAIT
tcp 0 0 127.0.0.1:9121 127.0.0.1:33524 TIME_WAIT
tcp 0 0 172.20.10.3:46346 54.192.218.69:443 TIME_WAIT
tcp 0 0 127.0.0.1:9090 127.0.0.1:48514 TIME_WAIT
tcp 0 0 127.0.0.1:9100 127.0.0.1:34518 TIME_WAIT
tcp 0 0 127.0.0.1:9187 127.0.0.1:37604 TIME_WAIT
tcp 0 0 127.0.0.1:9100 127.0.0.1:33996 TIME_WAIT
tcp 0 0 127.0.0.1:9090 127.0.0.1:48386 TIME_WAIT
tcp 0 0 127.0.0.1:9090 127.0.0.1:48900 TIME_WAIT
tcp 0 0 127.0.0.1:9187 127.0.0.1:37734 TIME_WAIT
tcp 0 0 127.0.0.1:9100 127.0.0.1:34382 TIME_WAIT
tcp 0 0 127.0.0.1:9121 127.0.0.1:33386 TIME_WAIT
tcp 0 0 127.0.0.1:9187 127.0.0.1:37474 TIME_WAIT
tcp 0 0 172.20.10.3:39282 91.189.88.149:80 TIME_WAIT
tcp 0 0 127.0.0.1:9100 127.0.0.1:34126 TIME_WAIT
tcp 0 0 172.20.10.3:47206 91.189.88.161:80 TIME_WAIT
tcp 0 0 127.0.0.1:9090 127.0.0.1:48644 TIME_WAIT
tcp 0 0 127.0.0.1:9100 127.0.0.1:34256 TIME_WAIT
tcp 0 0 127.0.0.1:9121 127.0.0.1:33258 TIME_WAIT
tcp 0 0 127.0.0.1:9121 127.0.0.1:33132 TIME_WAIT
tcp 0 0 127.0.0.1:9187 127.0.0.1:37872 TIME_WAIT
tcp6 0 0 ::1:9168 ::: LISTEN
tcp6 0 0 :::22 :::
LISTEN
tcp6 0 0 ::1:57282 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:9168 ::1:57380 TIME_WAIT
tcp6 0 0 ::1:57100 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:9168 ::1:57118 TIME_WAIT
tcp6 0 0 ::1:57546 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:57492 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:57408 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:57358 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:57232 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:9168 ::1:57518 TIME_WAIT
tcp6 0 0 ::1:9168 ::1:57250 TIME_WAIT
tcp6 0 0 ::1:9168 ::1:57026 TIME_WAIT
tcp6 0 0 ::1:57154 ::1:9168 TIME_WAIT
tcp6 0 0 ::1:57026 ::1:9168 TIME_WAIT

lcamilo15
17 days ago

@alexhaller I just pushed an arm version of this image lacarm/gitlab
https://hub.docker.com/r/lacarm/gitlab/

luisnabais
24 days ago

Hello.

I'm trying to add a custom Omniauth provider to this image, but it never recognizes it.

I've followed the tutorials in the websites below, but still nothing.
https://docs.gitlab.com/ce/integration/omniauth.html
https://docs.gitlab.com/ce/integration/omniauth.html#using-custom-omniauth-providers

Has anybody done that? Any tutorials online for this image to be able to do that? Or is it a limitation to this image in ay way?

Thank you very much

researchiteng
2 months ago

Some below asked how to run this container. The best way we came to run gitlab in docker containers (to ensure maximum performance and parameters as per documentation) is below.
We use this in a production with hundreds of users:

#/bin/bash -vx

#Desired version, unless one provided as argument
VERSION=${1:-'8.17.3-ce.0'}
#VERSION='8.13.0-ce.0'
#VERSION='latest'

echo "Going to use: gitlab/gitlab-ce:${VERSION} "

docker pull gitlab/gitlab-ce:${VERSION}
docker stop gitlab
docker rm gitlab

#This is req. in case you use SELinux:
chcon -Rt svirt_sandbox_file_t /storage/srv/gitlab/ || true
#/proc/sys/fs/file-max #this is shared with the host
GITLAB_FILEMAX=1000000
[[ $(cat /proc/sys/fs/file-max) -lt ${GITLAB_FILEMAX} ]] && echo $GITLAB_FILEMAX > /proc/sys/fs/file-max

# https://gitlab.com/gitlab-org/omnibus-gitlab/issues/1217 #mattermost docker containers
# # --sysctl vm.overcommit_memory=1 \
docker run --detach --name gitlab \
 --hostname gitlab.corp.dontbeevil.com \
 --sysctl net.core.somaxconn=1024 \
 --ulimit sigpending=62793 \
 --ulimit nproc=131072 \
 --ulimit nofile=60000 \
 --ulimit core=0 \
 --publish 443:443 --publish 80:80 --publish 22:22 --publish 8060:8060 \
 --restart always \
 --env GITLAB_OMNIBUS_CONFIG="external_url 'https://gitlab.corp.dontbeevil.com/'; gitlab_rails['lfs_enabled'] = true; mattermost_external_url 'http://mattermost.corp.dontbeevil.com';" \
 --volume /storage/srv/gitlab/config:/etc/gitlab:z \
 --volume /storage/srv/gitlab/logs:/var/log/gitlab:z \
 --volume /storage/srv/gitlab/data:/var/opt/gitlab:z \
 --volume /etc/localtime:/etc/localtime \
 gitlab/gitlab-ce:${VERSION}

# --privileged is required in order to set proper ulimits somaxconn, fs.file-max, etc; from all these, only file-max influences host, rest are only at cont. level.
# --ulimit sigpending=62793 --ulimit nproc=131072
# we cannot mount /proc/sys/net/core/somaxconn inside container (docker error:  cannot be mounted because it is located inside "/proc" )
# none of of capabilites help. We tried: docker run --ulimit sigpending=62793 --ulimit nproc=131072 --cap-add=CHOWN --cap-add=DAC_OVERRIDE --cap-add=FSETID --cap-add=FOWNER --cap-add=MKNOD --cap-add=NET_RAW --cap-add=SETGID --cap-add=SETUID --cap-add=SETFCAP --cap-add=SETPCAP --cap-add=NET_BIND_SERVICE --cap-add=SYS_CHROOT --cap-add=KILL --cap-add=AUDIT_WRITE gitlab/gitlab-ce

# To remove --privileged we need docker 1.12+ where we can set sysctl parameters on docker run, like we can ulimit parameters now. Till then, we need --privileged.

echo -e "waiting for services to start before checking status. So: sleeping 60 sec. \nFor startup status, if you want, you may want to ctrl+x and run: 'docker logs -f gitlab' or 'docker exec gitlab gitlab-ctl status' yourself."
sleep 60
docker exec gitlab gitlab-ctl status