Skip to content

Commit 56a0822

Browse files
authored
Merge pull request #2768 from sachilles/upgrade-to-16.0.0
Upgrade GitLab CE to 16.0.0
2 parents 1724a79 + 230284e commit 56a0822

File tree

15 files changed

+113
-47
lines changed

15 files changed

+113
-47
lines changed

Changelog.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@
22

33
This file only reflects the changes that are made in this image. Please refer to the upstream GitLab [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-foss/blob/master/CHANGELOG.md) for the list of changes in GitLab.
44

5+
**16.0.0**
6+
7+
- gitlab: upgrade CE to v16.0.0
8+
- gitaly: upgrade to v16.0.0
9+
- gitlab-pages: upgrade to v16.0.0
10+
- gitlab-shell: upgrade to v14.20.0
11+
512
**15.11.5**
613

714
- gitlab: upgrade CE to v15.11.5

Dockerfile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
FROM ubuntu:focal-20230412
22

3-
ARG VERSION=15.11.5
3+
ARG VERSION=16.0.0
44

55
ENV GITLAB_VERSION=${VERSION} \
66
RUBY_VERSION=3.0.6 \
77
RUBY_SOURCE_SHA256SUM="6e6cbd490030d7910c0ff20edefab4294dfcd1046f0f8f47f78b597987ac683e" \
88
GOLANG_VERSION=1.20.4 \
9-
GITLAB_SHELL_VERSION=14.18.0 \
10-
GITLAB_PAGES_VERSION=15.11.5 \
11-
GITALY_SERVER_VERSION=15.11.5 \
9+
GITLAB_SHELL_VERSION=14.20.0 \
10+
GITLAB_PAGES_VERSION=16.0.0 \
11+
GITALY_SERVER_VERSION=16.0.0 \
1212
GITLAB_USER="git" \
1313
GITLAB_HOME="/home/git" \
1414
GITLAB_LOG_DIR="/var/log/gitlab" \
@@ -45,7 +45,7 @@ RUN set -ex && \
4545
&& DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y \
4646
sudo supervisor logrotate locales curl \
4747
nginx openssh-server postgresql-contrib redis-tools \
48-
postgresql-client-12 postgresql-client-13 postgresql-client-14 postgresql-client-15 \
48+
postgresql-client-13 postgresql-client-14 postgresql-client-15 \
4949
python3 python3-docutils nodejs yarn gettext-base graphicsmagick \
5050
libpq5 zlib1g libyaml-0-2 libssl1.1 \
5151
libgdbm6 libreadline8 libncurses5 libffi7 \

README.md

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# sameersbn/gitlab:15.11.5
1+
# sameersbn/gitlab:16.0.0
22

33
[![CircleCI](https://circleci.com/gh/sameersbn/docker-gitlab/tree/master.svg?style=svg)](https://circleci.com/gh/sameersbn/docker-gitlab/tree/master)
44

@@ -125,7 +125,7 @@ Your docker host needs to have 1GB or more of available RAM to run GitLab. Pleas
125125
Automated builds of the image are available on [Dockerhub](https://hub.docker.com/r/sameersbn/gitlab) and is the recommended method of installation.
126126

127127
```bash
128-
docker pull sameersbn/gitlab:15.11.5
128+
docker pull sameersbn/gitlab:16.0.0
129129
```
130130

131131
You can also pull the `latest` tag which is built from the repository *HEAD*
@@ -194,7 +194,7 @@ docker run --name gitlab -d \
194194
--env 'GITLAB_SECRETS_SECRET_KEY_BASE=long-and-random-alpha-numeric-string' \
195195
--env 'GITLAB_SECRETS_OTP_KEY_BASE=long-and-random-alpha-numeric-string' \
196196
--volume /srv/docker/gitlab/gitlab:/home/git/data \
197-
sameersbn/gitlab:15.11.5
197+
sameersbn/gitlab:16.0.0
198198
```
199199

200200
*Please refer to [Available Configuration Parameters](#available-configuration-parameters) to understand `GITLAB_PORT` and other configuration options*
@@ -229,7 +229,7 @@ Volumes can be mounted in docker by specifying the `-v` option in the docker run
229229
```bash
230230
docker run --name gitlab -d \
231231
--volume /srv/docker/gitlab/gitlab:/home/git/data \
232-
sameersbn/gitlab:15.11.5
232+
sameersbn/gitlab:16.0.0
233233
```
234234

235235
### Database
@@ -288,7 +288,7 @@ docker run --name gitlab -d \
288288
--env 'DB_NAME=gitlabhq_production' \
289289
--env 'DB_USER=gitlab' --env 'DB_PASS=password' \
290290
--volume /srv/docker/gitlab/gitlab:/home/git/data \
291-
sameersbn/gitlab:15.11.5
291+
sameersbn/gitlab:16.0.0
292292
```
293293

294294
##### Linking to PostgreSQL Container
@@ -332,7 +332,7 @@ We are now ready to start the GitLab application.
332332
```bash
333333
docker run --name gitlab -d --link gitlab-postgresql:postgresql \
334334
--volume /srv/docker/gitlab/gitlab:/home/git/data \
335-
sameersbn/gitlab:15.11.5
335+
sameersbn/gitlab:16.0.0
336336
```
337337

338338
Here the image will also automatically fetch the `DB_NAME`, `DB_USER` and `DB_PASS` variables from the postgresql container as they are specified in the `docker run` command for the postgresql container. This is made possible using the magic of docker links and works with the following images:
@@ -371,7 +371,7 @@ The image can be configured to use an external redis server. The configuration s
371371
```bash
372372
docker run --name gitlab -it --rm \
373373
--env 'REDIS_HOST=192.168.1.100' --env 'REDIS_PORT=6379' \
374-
sameersbn/gitlab:15.11.5
374+
sameersbn/gitlab:16.0.0
375375
```
376376

377377
#### Linking to Redis Container
@@ -398,7 +398,7 @@ We are now ready to start the GitLab application.
398398

399399
```bash
400400
docker run --name gitlab -d --link gitlab-redis:redisio \
401-
sameersbn/gitlab:15.11.5
401+
sameersbn/gitlab:16.0.0
402402
```
403403

404404
#### Mail
@@ -411,7 +411,7 @@ If you are using Gmail then all you need to do is:
411411
docker run --name gitlab -d \
412412
--env '[email protected]' --env 'SMTP_PASS=PASSWORD' \
413413
--volume /srv/docker/gitlab/gitlab:/home/git/data \
414-
sameersbn/gitlab:15.11.5
414+
sameersbn/gitlab:16.0.0
415415
```
416416

417417
Please refer the [Available Configuration Parameters](#available-configuration-parameters) section for the list of SMTP parameters that can be specified.
@@ -431,7 +431,7 @@ docker run --name gitlab -d \
431431
--env '[email protected]' --env 'IMAP_PASS=PASSWORD' \
432432
--env 'GITLAB_INCOMING_EMAIL_ADDRESS=USER+%{key}@gmail.com' \
433433
--volume /srv/docker/gitlab/gitlab:/home/git/data \
434-
sameersbn/gitlab:15.11.5
434+
sameersbn/gitlab:16.0.0
435435
```
436436

437437
Please refer the [Available Configuration Parameters](#available-configuration-parameters) section for the list of IMAP parameters that can be specified.
@@ -515,7 +515,7 @@ docker run --name gitlab -d \
515515
--env 'GITLAB_SSH_PORT=10022' --env 'GITLAB_PORT=10443' \
516516
--env 'GITLAB_HTTPS=true' --env 'SSL_SELF_SIGNED=true' \
517517
--volume /srv/docker/gitlab/gitlab:/home/git/data \
518-
sameersbn/gitlab:15.11.5
518+
sameersbn/gitlab:16.0.0
519519
```
520520

521521
In this configuration, any requests made over the plain http protocol will automatically be redirected to use the https protocol. However, this is not optimal when using a load balancer.
@@ -531,7 +531,7 @@ docker run --name gitlab -d \
531531
--env 'GITLAB_HTTPS=true' --env 'SSL_SELF_SIGNED=true' \
532532
--env 'NGINX_HSTS_MAXAGE=2592000' \
533533
--volume /srv/docker/gitlab/gitlab:/home/git/data \
534-
sameersbn/gitlab:15.11.5
534+
sameersbn/gitlab:16.0.0
535535
```
536536

537537
If you want to completely disable HSTS set `NGINX_HSTS_ENABLED` to `false`.
@@ -554,7 +554,7 @@ docker run --name gitlab -d \
554554
--env 'GITLAB_SSH_PORT=10022' --env 'GITLAB_PORT=443' \
555555
--env 'GITLAB_HTTPS=true' --env 'SSL_SELF_SIGNED=true' \
556556
--volume /srv/docker/gitlab/gitlab:/home/git/data \
557-
sameersbn/gitlab:15.11.5
557+
sameersbn/gitlab:16.0.0
558558
```
559559

560560
Again, drop the `--env 'SSL_SELF_SIGNED=true'` option if you are using CA certified SSL certificates.
@@ -602,7 +602,7 @@ Let's assume we want to deploy our application to '/git'. GitLab needs to know t
602602
docker run --name gitlab -it --rm \
603603
--env 'GITLAB_RELATIVE_URL_ROOT=/git' \
604604
--volume /srv/docker/gitlab/gitlab:/home/git/data \
605-
sameersbn/gitlab:15.11.5
605+
sameersbn/gitlab:16.0.0
606606
```
607607

608608
GitLab will now be accessible at the `/git` path, e.g. `http://www.example.com/git`.
@@ -784,14 +784,14 @@ Also the container processes seem to be executed as the host's user/group `1000`
784784
```bash
785785
docker run --name gitlab -it --rm [options] \
786786
--env "USERMAP_UID=$(id -u git)" --env "USERMAP_GID=$(id -g git)" \
787-
sameersbn/gitlab:15.11.5
787+
sameersbn/gitlab:16.0.0
788788
```
789789

790790
When changing this mapping, all files and directories in the mounted data volume `/home/git/data` have to be re-owned by the new ids. This can be achieved automatically using the following command:
791791

792792
```bash
793793
docker run --name gitlab -d [OPTIONS] \
794-
sameersbn/gitlab:15.11.5 app:sanitize
794+
sameersbn/gitlab:16.0.0 app:sanitize
795795
```
796796

797797
#### Piwik
@@ -2449,7 +2449,7 @@ Execute the rake task to create a backup.
24492449

24502450
```bash
24512451
docker run --name gitlab -it --rm [OPTIONS] \
2452-
sameersbn/gitlab:15.11.5 app:rake gitlab:backup:create
2452+
sameersbn/gitlab:16.0.0 app:rake gitlab:backup:create
24532453
```
24542454

24552455
A backup will be created in the backups folder of the [Data Store](#data-store). You can change the location of the backups using the `GITLAB_BACKUP_DIR` configuration parameter.
@@ -2484,14 +2484,14 @@ you need to prepare the database:
24842484

24852485
```bash
24862486
docker run --name gitlab -it --rm [OPTIONS] \
2487-
sameersbn/gitlab:15.11.5 app:rake db:setup
2487+
sameersbn/gitlab:16.0.0 app:rake db:setup
24882488
```
24892489

24902490
Execute the rake task to restore a backup. Make sure you run the container in interactive mode `-it`.
24912491

24922492
```bash
24932493
docker run --name gitlab -it --rm [OPTIONS] \
2494-
sameersbn/gitlab:15.11.5 app:rake gitlab:backup:restore
2494+
sameersbn/gitlab:16.0.0 app:rake gitlab:backup:restore
24952495
```
24962496

24972497
The list of all available backups will be displayed in reverse chronological order. Select the backup you want to restore and continue.
@@ -2500,7 +2500,7 @@ To avoid user interaction in the restore operation, specify the timestamp, date
25002500

25012501
```bash
25022502
docker run --name gitlab -it --rm [OPTIONS] \
2503-
sameersbn/gitlab:15.11.5 app:rake gitlab:backup:restore BACKUP=1515629493_2020_12_06_13.0.6
2503+
sameersbn/gitlab:16.0.0 app:rake gitlab:backup:restore BACKUP=1515629493_2020_12_06_13.0.6
25042504
```
25052505

25062506
When using `docker-compose` you may use the following command to execute the restore.
@@ -2549,7 +2549,7 @@ The `app:rake` command allows you to run gitlab rake tasks. To run a rake task s
25492549

25502550
```bash
25512551
docker run --name gitlab -it --rm [OPTIONS] \
2552-
sameersbn/gitlab:15.11.5 app:rake gitlab:env:info
2552+
sameersbn/gitlab:16.0.0 app:rake gitlab:env:info
25532553
```
25542554

25552555
You can also use `docker exec` to run raketasks on running gitlab instance. For example,
@@ -2562,7 +2562,7 @@ Similarly, to import bare repositories into GitLab project instance
25622562

25632563
```bash
25642564
docker run --name gitlab -it --rm [OPTIONS] \
2565-
sameersbn/gitlab:15.11.5 app:rake gitlab:import:repos
2565+
sameersbn/gitlab:16.0.0 app:rake gitlab:import:repos
25662566
```
25672567

25682568
Or
@@ -2593,7 +2593,7 @@ Copy all the **bare** git repositories to the `repositories/` directory of the [
25932593

25942594
```bash
25952595
docker run --name gitlab -it --rm [OPTIONS] \
2596-
sameersbn/gitlab:15.11.5 app:rake gitlab:import:repos
2596+
sameersbn/gitlab:16.0.0 app:rake gitlab:import:repos
25972597
```
25982598

25992599
Watch the logs and your repositories should be available into your new gitlab container.
@@ -2617,12 +2617,12 @@ To upgrade to newer gitlab releases, simply follow this 4 step upgrade procedure
26172617

26182618
> **Note**
26192619
>
2620-
> Upgrading to `sameersbn/gitlab:15.11.5` from `sameersbn/gitlab:7.x.x` can cause issues. It is therefore required that you first upgrade to `sameersbn/gitlab:8.0.5-1` before upgrading to `sameersbn/gitlab:8.1.0` or higher.
2620+
> Upgrading to `sameersbn/gitlab:16.0.0` from `sameersbn/gitlab:7.x.x` can cause issues. It is therefore required that you first upgrade to `sameersbn/gitlab:8.0.5-1` before upgrading to `sameersbn/gitlab:8.1.0` or higher.
26212621
26222622
- **Step 1**: Update the docker image.
26232623

26242624
```bash
2625-
docker pull sameersbn/gitlab:15.11.5
2625+
docker pull sameersbn/gitlab:16.0.0
26262626
```
26272627

26282628
- **Step 2**: Stop and remove the currently running image
@@ -2647,7 +2647,7 @@ Replace `x.x.x` with the version you are upgrading from. For example, if you are
26472647
> **Note**: Since GitLab `8.11.0` you need to provide the `GITLAB_SECRETS_SECRET_KEY_BASE` and `GITLAB_SECRETS_OTP_KEY_BASE` parameters while starting the image. These should initially both have the same value as the contents of the `/home/git/data/.secret` file. See [Available Configuration Parameters](#available-configuration-parameters) for more information on these parameters.
26482648
26492649
```bash
2650-
docker run --name gitlab -d [OPTIONS] sameersbn/gitlab:15.11.5
2650+
docker run --name gitlab -d [OPTIONS] sameersbn/gitlab:16.0.0
26512651
```
26522652

26532653
### Shell Access
@@ -2685,7 +2685,7 @@ version: '2.3'
26852685

26862686
services:
26872687
gitlab:
2688-
image: sameersbn/gitlab:15.11.5
2688+
image: sameersbn/gitlab:16.0.0
26892689
healthcheck:
26902690
test: ["CMD", "/usr/local/sbin/healthcheck"]
26912691
interval: 1m

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
15.11.5
1+
16.0.0

assets/build/config/database.yml.postgresql

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,14 @@ production:
2929
# port: 8600
3030
# record: secondary.postgresql.service.consul
3131
# interval: 300
32+
ci:
33+
adapter: postgresql
34+
encoding: unicode
35+
database: gitlabhq_production
36+
database_tasks: false
37+
username: git
38+
password: "secure password"
39+
host: localhost
3240
# geo:
3341
# adapter: postgresql
3442
# encoding: unicode
@@ -50,6 +58,16 @@ development:
5058
host: localhost
5159
variables:
5260
statement_timeout: 15s
61+
ci:
62+
adapter: postgresql
63+
encoding: unicode
64+
database: gitlabhq_development
65+
database_tasks: false
66+
username: postgres
67+
password: "secure password"
68+
host: localhost
69+
variables:
70+
statement_timeout: 15s
5371
# geo:
5472
# adapter: postgresql
5573
# encoding: unicode
@@ -69,6 +87,14 @@ staging:
6987
username: git
7088
password: "secure password"
7189
host: localhost
90+
ci:
91+
adapter: postgresql
92+
encoding: unicode
93+
database: gitlabhq_staging
94+
database_tasks: false
95+
username: git
96+
password: "secure password"
97+
host: localhost
7298
# geo:
7399
# adapter: postgresql
74100
# encoding: unicode
@@ -91,10 +117,28 @@ test: &test
91117
prepared_statements: false
92118
variables:
93119
statement_timeout: 15s
120+
ci:
121+
adapter: postgresql
122+
encoding: unicode
123+
database: gitlabhq_test
124+
database_tasks: false
125+
username: postgres
126+
password:
127+
host: localhost
128+
prepared_statements: false
129+
variables:
130+
statement_timeout: 15s
94131
# geo:
95132
# adapter: postgresql
96133
# encoding: unicode
97134
# database: gitlabhq_geo_test
98135
# username: postgres
99136
# password:
100137
# host: localhost
138+
# embedding:
139+
# adapter: postgresql
140+
# encoding: unicode
141+
# database: gitlabhq_embedding_test
142+
# username: postgres
143+
# password:
144+
# host: localhost

assets/build/install.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,12 @@ git clone -q -b v${GITALY_SERVER_VERSION} --depth 1 ${GITLAB_GITALY_URL} ${GITLA
146146
# install gitaly
147147
make -C ${GITLAB_GITALY_BUILD_DIR} install
148148
mkdir -p ${GITLAB_GITALY_INSTALL_DIR}
149-
cp -a ${GITLAB_GITALY_BUILD_DIR}/ruby ${GITLAB_GITALY_INSTALL_DIR}/
149+
# The following line causes some issues. However, according to
150+
# <https://gitlab.com/gitlab-org/gitaly/-/merge_requests/5512> and
151+
# <https://gitlab.com/gitlab-org/gitaly/-/merge_requests/5671> there seems to
152+
# be some attempts to remove ruby from gitaly.
153+
#
154+
# cp -a ${GITLAB_GITALY_BUILD_DIR}/ruby ${GITLAB_GITALY_INSTALL_DIR}/
150155
cp -a ${GITLAB_GITALY_BUILD_DIR}/config.toml.example ${GITLAB_GITALY_INSTALL_DIR}/config.toml
151156
rm -rf ${GITLAB_GITALY_INSTALL_DIR}/ruby/vendor/bundle/ruby/**/cache
152157
chown -R ${GITLAB_USER}: ${GITLAB_GITALY_INSTALL_DIR}

assets/runtime/config/gitlabhq/database.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,12 @@ production:
1212
password: "{{DB_PASS}}"
1313
pool: {{DB_POOL}}
1414
prepared_statements: {{DB_PREPARED_STATEMENTS}}
15-
15+
ci:
16+
adapter: postgresql
17+
encoding: {{DB_ENCODING}}
18+
database: {{DB_NAME}}
19+
database_tasks: false
20+
host: {{DB_HOST}}
21+
port: {{DB_PORT}}
22+
username: {{DB_USER}}
23+
password: "{{DB_PASS}}"

contrib/docker-swarm/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ services:
2222

2323
gitlab:
2424
restart: always
25-
image: sameersbn/gitlab:15.11.5
25+
image: sameersbn/gitlab:16.0.0
2626
depends_on:
2727
- redis
2828
- postgresql

0 commit comments

Comments
 (0)