diff options
author | Shinya Maeda <shinya@gitlab.com> | 2017-10-30 15:55:18 +0300 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2017-10-30 15:55:18 +0300 |
commit | d6744d98384192799c9b3a97ad0eaf69cb4d25ee (patch) | |
tree | 68cb8a8002448165c350c6556175ba57befabe3a /app/services/clusters/gcp | |
parent | 478e59fe8d82b99800a2613aa4d153bf692fbd6b (diff) |
specs for services. Improved details.
Diffstat (limited to 'app/services/clusters/gcp')
-rw-r--r-- | app/services/clusters/gcp/finalize_creation_service.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/app/services/clusters/gcp/finalize_creation_service.rb b/app/services/clusters/gcp/finalize_creation_service.rb index 9f257bd0e9a..d379870924a 100644 --- a/app/services/clusters/gcp/finalize_creation_service.rb +++ b/app/services/clusters/gcp/finalize_creation_service.rb @@ -14,9 +14,11 @@ module Clusters provider.make_created! end rescue Google::Apis::ServerError, Google::Apis::ClientError, Google::Apis::AuthorizationError => e - cluster.make_errored!("Failed to request to CloudPlatform; #{e.message}") + provider.make_errored!("Failed to request to CloudPlatform; #{e.message}") + rescue KubeException => e + provider.make_errored!("Failed to request to Kubernetes; #{e.message}") rescue ActiveRecord::RecordInvalid => e - cluster.make_errored!("Failed to configure GKE Cluster: #{e.message}") + provider.make_errored!("Failed to configure GKE Cluster: #{e.message}") end private @@ -41,6 +43,8 @@ module Clusters return Base64.decode64(token_base64) if token_base64 end end + + nil end def gke_cluster |