为什么我在使用 Ansible 创建 S3 存储桶时遇到"This module has been removed"?


- name: Create S3 bucket
hosts: localhost
connection: local
gather_facts: false
tasks:
- name: Creating S3 bucket
s3: 
key_name: LampKey
bucket: biju-ansible-bucket
mode: create

我正在使用上面的代码来创建S3 bucket。

然而,当我运行上面的剧本时,我得到了这个错误:

TASK [Creating S3 bucket] *****************************************************************************************************************************
fatal: [localhost]: FAILED! => {"changed": false, "msg": "This module has been removed. The module documentation for Ansible-2.6 may contain hints for 
porting"}

为什么我会出现此错误?

was_s3替换模块s3解决了此错误

- name: Create S3 bucket
hosts: localhost
connection: local
gather_facts: false
tasks:
- name: Creating S3 bucket
aws_s3: 
aws_access_key: xx
aws_secret_key: yy
bucket: biju_ansible_bucket
mode: create

相关内容

最新更新