diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-20 14:10:13 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-20 14:10:13 +0300 |
commit | 0ea3fcec397b69815975647f5e2aa5fe944a8486 (patch) | |
tree | 7979381b89d26011bcf9bdc989a40fcc2f1ed4ff /scripts/prepare_build.sh | |
parent | 72123183a20411a36d607d70b12d57c484394c8e (diff) |
Add latest changes from gitlab-org/gitlab@15-1-stable-eev15.1.0-rc42
Diffstat (limited to 'scripts/prepare_build.sh')
-rw-r--r-- | scripts/prepare_build.sh | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/scripts/prepare_build.sh b/scripts/prepare_build.sh index 4b528696322..d68432d9ec0 100644 --- a/scripts/prepare_build.sh +++ b/scripts/prepare_build.sh @@ -17,8 +17,11 @@ else cp config/database.yml.postgresql config/database.yml fi -if [ -f config/database_geo.yml.postgresql ]; then - cp config/database_geo.yml.postgresql config/database_geo.yml +# Remove Geo database setting if `ee/` directory does not exist. When it does +# not exist, it runs the GitLab test suite "as if FOSS", meaning the jobs run +# in the context of gitlab-org/gitlab-foss where the Geo is not available. +if [ ! -d "ee/" ] ; then + sed -i '/geo:/,/^$/d' config/database.yml fi # Set user to a non-superuser to ensure we test permissions @@ -27,11 +30,6 @@ sed -i 's/username: root/username: gitlab/g' config/database.yml sed -i 's/localhost/postgres/g' config/database.yml sed -i 's/username: git/username: postgres/g' config/database.yml -if [ -f config/database_geo.yml ]; then - sed -i 's/localhost/postgres/g' config/database_geo.yml - sed -i 's/username: git/username: postgres/g' config/database_geo.yml -fi - cp config/cable.yml.example config/cable.yml sed -i 's|url:.*$|url: redis://redis:6379|g' config/cable.yml |