Manage cloud storage using libcloud
Anthony Shaw <anthonyshaw@apache.org>
Apache Libcloud Storage (object/blob) management for a full list of supported clouds, see http://libcloud.readthedocs.io/en/latest/storage/supported_providers.html
Clouds include Amazon S3, Google Storage, Aliyun, Azure Blobs, Ceph, OpenStack swift
New in version 2018.3.0.
This module uses a configuration profile for one or multiple Storage providers
libcloud_storage:
profile_test1:
driver: google_storage
key: GOOG0123456789ABCXYZ
secret: mysecret
profile_test2:
driver: s3
key: 12345
secret: mysecret
Examples
web_things:
libcloud_storage.container_present:
name: my_container_name
profile: profile1
libcloud_storage.object_present:
name: my_file.jpg
container: my_container_name
path: /path/to/local/file.jpg
profile: profile1
This example will download the file from the remote cloud and keep it locally
web_things:
libcloud_storage.file_present:
name: my_file.jpg
container: my_container_name
path: /path/to/local/file.jpg
profile: profile1
apache-libcloud
Ensures a container is absent.
name (str
) -- Container name
profile (str
) -- The profile key
Ensures a container is present.
name (str
) -- Container name
profile (str
) -- The profile key
Ensures a object is downloaded locally.
container (str
) -- Container name
name (str
) -- Object name in cloud
path (str
) -- Local path to file
profile (str
) -- The profile key
overwrite_existing (bool
) -- Replace if already exists
Ensures a object is absent.
container (str
) -- Container name
name (str
) -- Object name in cloud
profile (str
) -- The profile key
Ensures a object is presnt.
container (str
) -- Container name
name (str
) -- Object name in cloud
path (str
) -- Local path to file
profile (str
) -- The profile key