Rails4-carrierwave 为不同模型指定不同的bucket
Rails4-carrierwave specifying different bucket for different models
我正在使用载波将图像上传到 google 商店。有没有办法为不同的模型指定不同的桶。我试着保持
config.fog_directory = ''
in carrierwave.rb,然后在 store_dir 中写入存储桶的名称到个人上传者文件中,但出现以下错误:-
[fog][WARNING] fog: the specified google storage bucket name () is not a valid dns name. See: https://developers.google.com/storage/docs/bucketnaming
Completed 500 Internal Server Error in 815ms (ActiveRecord: 1.1ms)
Excon::Errors::SocketError (getaddrinfo: No address associated with hostname >(SocketError)):
我正在使用载波将图像上传到 google 商店。有没有办法为不同的模型指定不同的桶。我试着保持
config.fog_directory = ''
in carrierwave.rb,然后在 store_dir 中写入存储桶的名称到个人上传者文件中,但出现以下错误:-
[fog][WARNING] fog: the specified google storage bucket name () is not a valid dns name. See: https://developers.google.com/storage/docs/bucketnaming Completed 500 Internal Server Error in 815ms (ActiveRecord: 1.1ms)
Excon::Errors::SocketError (getaddrinfo: No address associated with hostname >(SocketError)):