Skip to content

Commit 1f3469c

Browse files
Robert Marshallstanhu
andcommitted
Merge branch 'sh-suppress-ruby-experimental-warnings' into 'master'
Suppress Ruby experimental features warning messages See merge request https://gitlab.com/gitlab-org/omnibus-gitlab/-/merge_requests/7137 Merged-by: Robert Marshall <[email protected]> Approved-by: Jason Plum <[email protected]> Approved-by: Robert Marshall <[email protected]> Co-authored-by: Stan Hu <[email protected]>
2 parents eca9f47 + 18cb56c commit 1f3469c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

config/templates/gitlab-rails/bundle_exec_wrapper.erb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,7 @@ else
4040
privilege_drop="-u ${gitlab_user}:${gitlab_group}"
4141
fi
4242

43-
exec <%= install_dir %>/embedded/bin/chpst -e <%= install_dir %>/etc/gitlab-rails/env ${privilege_drop} -U ${gitlab_user}:${gitlab_group} <%= install_dir %>/embedded/bin/bundle exec <%= command %>
43+
# Suppress one-line pattern matching warnings: https://gitlab.com/gitlab-org/gitlab/-/issues/420811
44+
rubyopt="RUBYOPT=-W:no-experimental"
45+
46+
exec <%= install_dir %>/embedded/bin/chpst -e <%= install_dir %>/etc/gitlab-rails/env ${privilege_drop} -U ${gitlab_user}:${gitlab_group} /usr/bin/env ${rubyopt} <%= install_dir %>/embedded/bin/bundle exec <%= command %>

0 commit comments

Comments
 (0)