1
0
Fork 0
This repository has been archived on 2024-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
Ansible_Project/roles/ansistrano.deploy/tasks/update-code/s3.yml

33 lines
1.3 KiB
YAML
Raw Permalink Normal View History

2022-05-02 17:37:08 +02:00
---
- name: ANSISTRANO | S3 | Create release folder
file:
state: directory
path: "{{ ansistrano_release_path.stdout }}"
- name: ANSISTRANO | S3 | Get object from S3
aws_s3:
bucket: "{{ ansistrano_s3_bucket }}"
object: "{{ ansistrano_s3_object }}"
dest: "{{ ansistrano_release_path.stdout }}/{{ ansistrano_s3_object | basename }}"
mode: get
region: "{{ ansistrano_s3_region }}"
aws_access_key: "{{ ansistrano_s3_aws_access_key | default(omit) }}"
aws_secret_key: "{{ ansistrano_s3_aws_secret_key | default(omit) }}"
ignore_nonexistent_bucket: "{{ ansistrano_s3_ignore_nonexistent_bucket | default(omit) }}"
when: not ansistrano_s3_rgw
- name: ANSISTRANO | S3 | Get object from Ceph RGW
aws_s3:
rgw: true
s3_url: "{{ ansistrano_s3_url }}"
encrypt: "{{ ansistrano_s3_encrypt | default(false) }}"
bucket: "{{ ansistrano_s3_bucket }}"
object: "{{ ansistrano_s3_object }}"
dest: "{{ ansistrano_release_path.stdout }}/{{ ansistrano_s3_object | basename }}"
mode: get
aws_access_key: "{{ ansistrano_s3_aws_access_key | default(omit) }}"
aws_secret_key: "{{ ansistrano_s3_aws_secret_key | default(omit) }}"
region: "{{ ansistrano_s3_region | default(omit) }}"
ignore_nonexistent_bucket: "{{ ansistrano_s3_ignore_nonexistent_bucket | default(omit) }}"
when: ansistrano_s3_rgw