标签: ruby-on-rails amazon-web-services
我在application.yml上设置aws凭据
AWS_KEY: 'myKey' AWS_SECRET: 'mySecret'
然后
s3 = Aws::S3::Client.new
成功返回客户端,但是当我尝试获取对象时
resp = s3.get_object(bucket:'my-bucket', key:'myFile.txt')
我收到以下错误。
Aws::Errors::MissingCredentialsError: