fix Aliyun::OSS::ServerError: OSS authentication requires a valid Date #85
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
ubuntu 18.04
'2.3.0 :026 >ruby 2.5.1
there are ServerError, must add headers['x-oss-date']
Aliyun::OSS::ServerError: RequestId: 5F816C573E13173631578A19, Code: AccessDenied, Message: OSS authentication requires a valid Date., HostId: oss-cn-shanghai.aliyuncs.com, HTTPCode: 403
from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/http.rb:275:in
block in do_request' from xxx/.rvm/gems/ruby-2.3.0/gems/rest-client-2.0.2/lib/restclient/request.rb:807:in
process_result'from xxx/.rvm/gems/ruby-2.3.0/gems/rest-client-2.0.2/lib/restclient/request.rb:725:in
block in transmit' from xxx/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/net/http.rb:853:in
start'from xxx/.rvm/gems/ruby-2.3.0/gems/rest-client-2.0.2/lib/restclient/request.rb:715:in
transmit' from xxx/.rvm/gems/ruby-2.3.0/gems/rest-client-2.0.2/lib/restclient/request.rb:145:in
execute'from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/http.rb:271:in
do_request' from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/http.rb:186:in
get'from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/protocol.rb:54:in
list_buckets' from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/iterator.rb:49:in
fetch'from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/iterator.rb:40:in
fetch_more' from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/iterator.rb:23:in
block in next'from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/iterator.rb:21:in
loop' from xxx/.rvm/gems/ruby-2.3.0/gems/aliyun-sdk-0.8.0/lib/aliyun/oss/iterator.rb:21:in
next'from (irb):25:in
each' from (irb):25 from xxx/.rvm/rubies/ruby-2.3.0/bin/irb:11:in