Add 'gdk rake' command
What does this merge request do and why?
This adds a gdk rake command that replaces the usage of
bundle exec rake. The latter has been causing problems in Ruby child
processes because it sets the BUNDLER_SETUP and RUBYOPT environment
variables, which causes the GDK Bundler to run in GDK services, which
might be using a different version of Bundler or Ruby.
This isolation provides both a convenient utility and entrypoint by
making gdk rake available in all GDK subprojects, for example the
gitlab monolith repository. It also improves the stability and
reproducibility of running Rake tasks via GDK.
This also discourages the use of bundle exec rake through a warning to stderr.
Closes Make 'bundle exec rake' more stable or discoura... (#2690 - closed)
How to set up and validate locally
Run gdk rake --help or gdk rake -T to list all tasks.
gdk rake [...] should work the exact same as bundle exec rake [...].
Impacted categories
The following categories relate to this merge request:
-
gdk-reliability - e.g. When a GDK action fails to complete. -
gdk-usability - e.g. Improvements or suggestions around how the GDK functions. -
gdk-performance - e.g. When a GDK action is slow or times out.
Merge request checklist
-
This MR references an issue describing the change. -
This change is backward compatible. If not, please include steps to communicate to our users. -
Tests added for new functionality. If not, please raise an issue to follow-up. -
Documentation added/updated, if needed. -
Announcement added, if change is notable. -
gdk doctortest added, if needed.