Skip to content

Commit

Permalink
Echo to user the service being used
Browse files Browse the repository at this point in the history
  • Loading branch information
mikkergimenez committed Nov 4, 2019
1 parent 7e27542 commit 77a51ed
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
6 changes: 2 additions & 4 deletions lib/vmfloaty/abs.rb
Original file line number Diff line number Diff line change
Expand Up @@ -155,24 +155,22 @@ def self.retrieve(verbose, os_types, token, url, user)
# "job": {
# "id": "12345",
# "tags": {
# "user": "jenkins",
# "jenkins_build_url": "https://jenkins/job/platform_puppet_intn-van-sys_master"
# "user": "username",
# }
# }
# }

conn = Http.get_conn(verbose, url)
conn.headers['X-AUTH-TOKEN'] = token if token

saved_job_id = Time.now.to_i
saved_job_id = DateTime.now.strftime('%Q')

reqObj = {
:resources => os_types,
:job => {
:id => saved_job_id,
:tags => {
:user => user,
:url_string => "floaty://#{user}/#{saved_job_id}",
},
},
}
Expand Down
1 change: 1 addition & 0 deletions lib/vmfloaty/utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ def self.get_service_config(config, options)
service_config['token'] = options.token unless options.token.nil?
service_config['user'] = options.user unless options.user.nil?

puts "Connecting to service #{service_config['type']} at #{service_config['url']} as #{service_config['user']}...\n\n"
service_config
end
end

0 comments on commit 77a51ed

Please sign in to comment.