Skip to content

Remove ci_runner_limits feature flag

What does this MR do and why?

Describe in detail what your merge request does and why.

This MR removes the ci_runner_limits FF which has been in production on .com since Sep 29 10:26 UTC. Self-hosted users will still have a way to overcome limits either by using the override FF or by updating the plan limits.

TODO

Screenshots or screen recordings

These are strongly recommended to assist reviewers and reduce the time to merge your change.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Create a test project called test-runner-limit at http://localhost:3000/root/

  2. Testing project limits:

    1. Navigate to http://localhost:3000/root/test-runner-limit/-/settings/ci_cd#js-runners-settings and start registering runners using the designated runner registration token until you reach the limit defined for :ci_registered_project_runners:

      Registration command
      # Write to /tmp/config.gdk.toml so we can just unregister all runners from that file at the end 
      gitlab-runner register -config /tmp/config.gdk.toml \
              --non-interactive \
              --executor "shell" \
              --url "http://localhost:3000/" \
              --description "project test runner" \
              --tag-list "shell,gdk" \
              --run-untagged="false" \
              --locked="false" \
              --access-level="not_protected" \
              --registration-token="..." # Project runner registration token
    2. Once the limit is reached you should start getting HTTP 400 errors from gitlab-runner register (unless you enable ci_runner_limits_override for the project)

  3. Testing group limits:

    1. Navigate to e.g. http://localhost:3000/groups/gitlab-org/-/settings/ci_cd#js-runners-settings (this group should exist in the GDK installation) and start registering runners using the designated runner registration token until you reach the limit defined for :ci_registered_group_runners:

      Registration command
      # Write to /tmp/config.gdk.toml so we can just unregister all runners from that file at the end 
      gitlab-runner register -config /tmp/config.gdk.toml \
              --non-interactive \
              --executor "shell" \
              --url "http://localhost:3000/" \
              --description "group test runner" \
              --tag-list "shell,gdk" \
              --run-untagged="false" \
              --locked="false" \
              --access-level="not_protected" \
              --registration-token="..." # Group runner registration token
    2. Once the limit is reached you should start getting HTTP 400 errors from gitlab-runner register (unless you enable ci_runner_limits_override for the group)

    3. You can also verify that creating other runners in other groups is disallowed if the limit has been reached

  4. Clean-up:

    # Unregister all runners in temporary config file
    gitlab-runner --config /tmp/config.gdk.toml unregister --all-runners && rm -f /tmp/config.gdk.toml

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Closes #329438 (closed)

Edited by Pedro Pombeiro

Merge request reports