如何使用Paperclip复制文件

有没有人知道用Paperclip使用S3存储复制文件的方法? 在我尝试自己编写之前,我只是想确保没有办法做到这一点。 谢谢

经过一些纸夹后,我想通了。 复制文件真是太简单了!

# Stupid example method that just copies a user's profile pic to another user. def copy_profile_picture(user_1, user_2) user_2.picture = user_1.picture user_2.save # Copied the picture and we're done! end 

这也适用于amazon s3。 甜