Skip to content

Don't require a bucket if object storage is disabled for a type

Stan Hu requested to merge sh-allow-storage-specific-objectstore-disable into master

Previously if a user enabled consolidated settings then selectively disabled some object storage types, they were still required to set a bucket name for that object type. For example:

  1. Enable consolidated object storage (https://docs.gitlab.com/ee/administration/object_storage.html).

  2. Configure the artifacts object storage with the below:

gitlab_rails['object_store']['objects']['artifacts']['enabled'] = false

gitlab_rails['artifacts_enabled'] = true

Reconfigure GitLab and you see this error:

Object storage for artifacts must have a bucket specified

Since the previous workaround would be to set a dummy bucket name, this change skips assigning consolidated settings if object storage has been disabled for a specific type.

Relates to #233826 (closed)

Edited by Stan Hu

Merge request reports

Loading