diff options
author | Tomasz Maczukin <tomasz@maczukin.pl> | 2016-11-21 16:02:08 +0100 |
---|---|---|
committer | Tomasz Maczukin <tomasz@maczukin.pl> | 2016-11-21 19:49:29 +0100 |
commit | 461195665b22291d5e57287efc0567b89a9ee262 (patch) | |
tree | 3c229496caf9c638929741b1771e00faf9f86f27 /app/models | |
parent | e3fb0740228219433a4623dc0b9325785e23ae16 (diff) | |
download | gitlab-ce-461195665b22291d5e57287efc0567b89a9ee262.tar.gz |
Add Gitlab::Ci::Build::Credentials module with build credentials abstraction
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/ci/build.rb | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb index ac3fff3fb0c..7403a46969f 100644 --- a/app/models/ci/build.rb +++ b/app/models/ci/build.rb @@ -449,18 +449,11 @@ module Ci end def credentials - [build_container_registry_credentials].compact + Gitlab::Ci::Build::Credentials::Factory.new(self).create! end private - def build_container_registry_credentials - return unless Gitlab.config.registry.enabled - - Gitlab::Ci::Build::Credentials.new('docker-registry', Gitlab.config.registry.host_port, - 'gitlab-ci-token', token) - end - def update_artifacts_size self.artifacts_size = if artifacts_file.exists? artifacts_file.size |