Class: BeamUp::Providers::SealStatic
- Defined in:
- lib/beam_up/providers/seal_static.rb
Defined Under Namespace
Classes: Config
Constant Summary collapse
- BASE_URL =
"https://app.sealstatic.com/api"
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from BeamUp::Providers::Base
Instance Method Details
#deploy!(path) ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/beam_up/providers/seal_static.rb', line 29 def deploy!(path) @path = path zipped_file = create_zip(path) BeamUp.progress&.start(type: :bytes, total: zipped_file.size) response = upload zipped_file return Result.new(provider: "Seal Static", error: response["error"]) if response["error"] Result.new( provider: "Seal Static", url: response["url"] ) rescue => error Result.new(provider: "Seal Static", error: error.) ensure BeamUp.progress&.finish zipped_file&.close! end |