Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-10-03 15:08:27 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-10-03 15:08:27 +0300
commit077b0a79d52753d020280ed8d58f97f8207b42de (patch)
tree79c6a7d3bbc41915acfff72e4620e7c4490528bf /scripts/review_apps
parent10d4625ed3b73f73bc67bf7d35347dcd1912cf7b (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'scripts/review_apps')
-rwxr-xr-xscripts/review_apps/review-apps.sh8
1 files changed, 2 insertions, 6 deletions
diff --git a/scripts/review_apps/review-apps.sh b/scripts/review_apps/review-apps.sh
index e979d0f75cf..a50db8b6f5d 100755
--- a/scripts/review_apps/review-apps.sh
+++ b/scripts/review_apps/review-apps.sh
@@ -154,12 +154,8 @@ function disable_sign_ups() {
true
fi
- # Create the root token
- local set_token_rb="token = User.find_by_username('root').personal_access_tokens.create(scopes: [:api], name: 'Token to disable sign-ups'); token.set_token('${REVIEW_APPS_ROOT_TOKEN}'); begin; token.save!; rescue(ActiveRecord::RecordNotUnique); end"
- retry "run_task \"${set_token_rb}\""
-
- # Disable sign-ups
- local disable_signup_rb="Gitlab::CurrentSettings.current_application_settings.update!(signup_enabled: false)"
+ # Create the root token + Disable sign-ups
+ local disable_signup_rb="token = User.find_by_username('root').personal_access_tokens.create(scopes: [:api], name: 'Token to disable sign-ups'); token.set_token('${REVIEW_APPS_ROOT_TOKEN}'); begin; token.save!; rescue(ActiveRecord::RecordNotUnique); end; Gitlab::CurrentSettings.current_application_settings.update!(signup_enabled: false)"
if (retry "run_task \"${disable_signup_rb}\""); then
echoinfo "Sign-ups have been disabled successfully."
else