sameersbn / sameersbn/docker-gitlab

RELATIVE_URL_ROOT does not work !!

Open
#2,600 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
8.1k
Forks
2.1k
Avg merge
17h 47m
Merged PRs (30d)
7

Description

Hello
Gitlab does not follow the subpath defined in the RELATIVE_URL_ROOT environment variable. I saw that gitlab-ce recommends using a subdomain instead, but that's not possible in my infrastructure. So can't I use Gitlab ?

Here the installation script :

docker run --name gitlab-postgresql -d \
    --env 'DB_NAME=gitlabhq_production' \
    --env 'DB_USER=gitlab' --env 'DB_PASS=password' \
    --env 'DB_EXTENSION=pg_trgm,btree_gist' \
    --volume /Users/nicolas/docker/gitlab/postgresql:/var/lib/postgresql \
    sameersbn/postgresql:12-20200524


docker run --name gitlab-redis -d \
    --volume /Users/nicolas/docker/gitlab/redis:/data \
    redis:6.2

docker run --name gitlab -d \
    --link gitlab-postgresql:postgresql --link gitlab-redis:redisio \
    --publish 10022:22 --publish 8083:80 \
    --env 'GITLAB_PORT=8083' --env 'GITLAB_SSH_PORT=10022' \
    --env 'GITLAB_SECRETS_DB_KEY_BASE=long-and-random-alpha-numeric-string' \
    --env 'GITLAB_SECRETS_SECRET_KEY_BASE=long-and-random-alpha-numeric-string' \
    --env 'GITLAB_SECRETS_OTP_KEY_BASE=long-and-random-alpha-numeric-string' \
    --env 'RELATIVE_URL_ROOT=/gitlab'  \
    --volume /Users/nicolas/docker/gitlab/gitlab:/home/git/data \
    sameersbn/gitlab:15.0.3

As you can see it does not work : It does not redirect to http://localhost:8083/gitlab/users/sign_in

$ curl http://localhost:8083/gitlab

<html><body>You are being <a href="http://localhost:8083/users/sign_in">redirected</a>.</body></html>                           

Please, help me

Best regards

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the problem with the supplied docker run commands and curl request, then trace how the RELATIVE_URL_ROOT environment variable is consumed in the GitLab container. Done means /gitlab redirects to /gitlab/users/sign_in rather than /users/sign_in; the report names no file or test.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, shell
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.