2017-07-27 4 views
0

を取得するときAnsible AWS S3は、ディレクトリchecksuomに失敗:次Ansibleコマンドを使用してS3バケットからオブジェクトを取得するときにオブジェクト

fatal: [som_fake_host]: FAILED! => { 
    "changed": false, 
    "failed": true, 
    "invocation": { 
     "module_args": { 
      "aws_access_key": null, 
      "aws_secret_key": null, 
      "bucket": "some-fake-bucket", 
      "dest": "/some-fake-dest/", 
      "ec2_url": null, 
      "encrypt": true, 
      "expiry": "600", 
      "headers": null, 
      "ignore_nonexistent_bucket": false, 
      "marker": null, 
      "max_keys": "1000", 
      "metadata": null, 
      "mode": "get", 
      "object": "some_fake_file", 
      "overwrite": "always", 
      "permission": [ 
       "private" 
      ], 
      "prefix": null, 
      "profile": null, 
      "region": null, 
      "retries": 0, 
      "rgw": false, 
      "s3_url": null, 
      "security_token": null, 
      "src": null, 
      "validate_certs": true, 
      "version": null 
     } 
    }, 
    "msg": "attempted to take checksum of directory: /some-fake-dest/" 
} 

さらなる有用な:

- name: "copy object from s3://{{ s3_bucket }}/{{ s3_object }} to {{ dest }}" 
    s3: 
    bucket: "{{ s3_bucket }}" 
    object: "{{ s3_object }}" 
    dest: "{{ dest }}" 
    mode: get 

私は次のエラーを取得情報:

  • 宛先ディレクトリが存在します。
  • 脚本を実行するユーザーは、ファイルがdocsを見てS3バケットに

答えて

1

が存在する先のディレクトリ

  • 上の権限を持っている:

    dest The destination file path when downloading an object/key with a GET operation.

    ディレクトリ、ファイルパスでモジュールを呼び出すしないようにしてください。例:

    dest: "{{ dest }}/{{ s3_object }}" 
    

    または何か。

  • +0

    ありがとうございました dest: "{{dest}}/{{s3_object}}" –

    関連する問題