Compare client/server versions and warn if different
This commit is contained in:
@@ -17,6 +17,7 @@ module Faaso
|
||||
Log.info { "Building function... #{funko.name} in #{tmp_dir}" }
|
||||
funko.build tmp_dir
|
||||
else # Running against a server
|
||||
Faaso.check_version
|
||||
# Create a tarball for the funko
|
||||
buf = IO::Memory.new
|
||||
Compress::Gzip::Writer.open(buf) do |gzip|
|
||||
|
@@ -27,6 +27,7 @@ module Faaso
|
||||
end
|
||||
|
||||
def remote(options, name, scale) : Int32
|
||||
Faaso.check_version
|
||||
if !scale
|
||||
Crest.get(
|
||||
"#{FAASO_SERVER}funkos/#{name}/scale/", \
|
||||
|
@@ -13,6 +13,7 @@ module Faaso
|
||||
end
|
||||
|
||||
def remote(options, funko, name, secret) : Int32
|
||||
Faaso.check_version
|
||||
if options["--add"]
|
||||
Crest.post(
|
||||
"#{FAASO_SERVER}secrets/",
|
||||
|
@@ -26,6 +26,7 @@ module Faaso
|
||||
end
|
||||
|
||||
def remote(options, name) : Int32
|
||||
Faaso.check_version
|
||||
Crest.get(
|
||||
"#{FAASO_SERVER}funkos/#{name}/status/", \
|
||||
user: "admin", password: "admin") do |response|
|
||||
|
Reference in New Issue
Block a user