Skip to content

WIP: Enable default build timeouts

What does this MR do?

Adds the ability to configure the default build timeout in the application settings panel.

WIP for the moment because the builds are failing and I have no clue why. Seems master is failing, though, so it might not be my fault. Tests of only my patches on 8.11.5 appear to work. Will resync and squash tomorrowish.

Are there points in the code the reviewer needs to double check?

Not sure why there some defaults are formatted differently, so mine may be incorrect (though it's working)

default_value_for :container_registry_enabled, gitlab_config_features.container_registry
default_value_for(:repository_storage) { current_application_settings.repository_storage }
default_value_for(:build_timeout) {current_application_settings.default_runner_timeout_minutes * 60}

Check the schema and migration, I've never made on before. My tests were on a fresh 8.11.5 install with only these patches applied and the DB updated by hand.

Why was this MR needed?

The current timeout is set at the database level and defaulted to when a project is created. This allows for admin configuration of the default value.

Screenshots (if relevant)

runner_timeout

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

#22081 (moved)

Merge request reports