如何使用对象存储来储存gitlab的数据

我在阿里云上用docker搭建了一个gitlab-ce,发现硬盘占用消耗的太快,应该是Container Registry 占的比较多,请问如何用aliyun的OSS作为gitlab的存储?

可以参考文档:( 对象存储 | 极狐GitLab)

阿里云的OSS支持吗

支持的,阿里云oss和腾讯云对象存储都试过

文档里没写阿里云的,有配置的样例吗

阿里云oss配置样例如下:

# oss 配置
gitlab_rails['object_store']['enabled'] = true
gitlab_rails['object_store']['connection'] = {
  'provider' => 'AWS',
  'region' => 'oss-ap-northeast-1',
  'aws_access_key_id' => 'LTAI5tFDkxxxxxxxxBf4Zo2C',
  'aws_secret_access_key' => 'plsKlpm9xxxxxxxx0cW3cCBQOW',
  'endpoint' => 'http://oss-ap-northeast-1.aliyuncs.com',
  'path_style' => 'true'
}

gitlab_rails['object_store']['proxy_download'] = true
gitlab_rails['object_store']['objects']['artifacts']['bucket'] = 'gitlab-artifacts-storage'
gitlab_rails['object_store']['objects']['external_diffs']['bucket'] = 'gitlab-external-diffs-storage'
gitlab_rails['object_store']['objects']['lfs']['bucket'] = 'gitlab-lfs-storage'
gitlab_rails['object_store']['objects']['uploads']['bucket'] = 'gitlab-uploads-storage'
gitlab_rails['object_store']['objects']['packages']['bucket'] = 'gitlab-packages-storage'
gitlab_rails['object_store']['objects']['dependency_proxy']['bucket'] = 'gitlab-dependency-proxy-storage'
gitlab_rails['object_store']['objects']['terraform_state']['bucket'] = 'gitlab-terraform-state-storage'
gitlab_rails['object_store']['objects']['pages']['bucket'] = 'gitlab-pages-storage'