Class: Opsk::Deploy
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Opsk::Deploy
- Includes:
- Thorable, Thor::Actions
- Defined in:
- lib/opskeleton/deploy.rb
Instance Method Summary collapse
Methods included from Thorable
#artifact, #artifact_path, included, #machines, #meta, #name, #type_of
Instance Method Details
#upload ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/opskeleton/deploy.rb', line 10 def upload require 'bintray_deploy' pkg = Opsk::Package.new tar = "#{pkg.artifact_path}.tar.gz" base = File.basename(tar) if(File.exists?(tar)) begin BintrayDeploy::Actions.new.deploy(repo, "#{pkg.meta.name}-sandbox", pkg..version, tar) say("deployed #{base} to http://dl.bintray.com/#{C.user}/#{repo}/#{base}") rescue Exception => e say("failed to deploy due to #{e}") end else say('package is missing please run opsk package first') end end |