[file-store-6] change upload url
This commit is contained in:
parent
7af613e707
commit
4c6acc8702
|
@ -26,7 +26,7 @@ Dir.glob("*.{bz2,rar,gz,tar,tbz2,tgz,zip,Z,7z,xz,lzma}").uniq.sort.each do |file
|
|||
puts " file \"#{file}\" already exists in the file-store"
|
||||
elsif resp == []
|
||||
# try to put file at file-store
|
||||
resp = JSON(rclient.post :file_store => {:file => File.new(file, 'rb')})
|
||||
resp = JSON `curl --user #{ARGF.argv[0]}: -POST -F "file_store[file]=@#{file}" http://file-store.rosalinux.ru/api/v1/upload`
|
||||
unless resp['sha1_hash'].nil?
|
||||
new_sources << " \"#{file}\": #{sha1}"
|
||||
FileUtils.rm_rf file
|
||||
|
|
Loading…
Reference in New Issue