English 中文(简体)
承运人波/纸质剪贴和回收 -- -- 在若干计算机之间共享
原标题:Carrierwave/Paperclip and Resque - Sharing across several computers

我正在研究一个铁路应用程序,该应用程序要求将文件上传到我的服务器上,然后让重新整理的工人(在其他几个计算机上运行)使用这些文件来完成某些任务。 我的工人都准备完成这项任务,但我似乎无法找到一个很好的方法将文件从主机的电脑上拿到我的工人电脑上。我尝试了Carter波(并查看了Paperclip的文件),但我所看到的只是用的是S3,我无法使用。我的唯一想法是存储一个包含URI的字符串,其中含有可以找到的文件的URI,以便工人能够下载这些文件并开始工作。我特别不喜欢这个想法。有人建议什么是这样做的最佳方法吗?谢谢!


更新更新更新

我还要指出,需要分享的档案大约各200MB

最佳回答

您是否考虑过类似的“http://de.wikipedia.org/wiki/Network_File_System” rel = “nofollow”>Network 文件系统 ,而不是在您的应用程序中这样做?

取决于您的工人和服务器是哪个平台, 您应该有许多共享文件系统的选项( 我猜您之间有局域网运行 ) 。

即使没有真正的局域网,sshfs 也可以工作。

好处显而易见: 您的 Ruby 应用程序只需要用 FileUtls 处理一个常规文件系统, 并且用更可靠的基础设施 来处理重推车的重推车。

问题回答

暂无回答




相关问题
rails collection_select vs. select

collection_select and select Rails helpers: Which one should I use? I can t see a difference in both ways. Both helpers take a collection and generates options tags inside a select tag. Is there a ...

SSL slowness in EC2

We ve deployed our rails app to EC2. In our setup, we have two proxies on small instances behind round-robin DNS. These run nginx load balancers for a dynamically growing and shrinking farm of web ...

Auth-code with A-Za-z0-9 to use in an URL parameter

As part of a web application I need an auth-code to pass as a URL parameter. I am currently using (in Rails) : Digest::SHA1.hexdigest((object_id + rand(255)).to_s) Which provides long strings like : ...

RubyCAS-Client question: Rails

I ve installed RubyCAS-Client version 2.1.0 as a plugin within a rails app. It s working, but I d like to remove the ?ticket= in the url. Is this possible?

activerecord has_many :through find with one sql call

I have a these 3 models: class User < ActiveRecord::Base has_many :permissions, :dependent => :destroy has_many :roles, :through => :permissions end class Permission < ActiveRecord::...

Ordering a hash to xml: Rails

I m building an xml document from a hash. The xml attributes need to be in order. How can this be accomplished? hash.to_xml

Text Editor for Ruby-on-Rails

guys which text editor is good for Rubyonrails? i m using Windows and i was using E-Texteditor but its not free n its expired now can anyone plese tell me any free texteditor? n which one is best an ...

How to get SQL queries for each user where env is production

I’m developing an application dedicated to generate statistical reports, I would like that user after saving their stat report they save sql queries too. To do that I wrote the following module: ...

热门标签