--- dup.bak 2011-09-28 11:43:59.828894897 +0300 +++ dup 2011-09-28 11:44:04.256679895 +0300 @@ -29,6 +29,9 @@ getconf desturl getconf awsaccesskeyid getconf awssecretaccesskey +getconf cfusername +getconf cfapikey +getconf cfauthurl getconf ftp_password getconf sshoptions getconf bandwidthlimit 0 @@ -45,6 +48,9 @@ if [ "`echo $desturl | /usr/bin/awk -F ':' '{print $1}'`" == "s3+http" ]; then [ -n "$awsaccesskeyid" -a -n "$awssecretaccesskey" ] || fatal "AWS access keys must be set for S3 backups." fi +if [ "`echo $desturl | /usr/bin/awk -F ':' '{print $1}'`" == "cf+http" ]; then + [ -n "$cfusername" -a -n "$cfapikey" ] || fatal "Cloudfiles access keys must be set for S3 backups." +fi if [ "`echo $desturl | /usr/bin/awk -F ':' '{print $1}'`" == "ftp" ]; then [ -n "$ftp_password" ] || fatal "ftp_password must be set for FTP backups." fi @@ -266,6 +272,14 @@ export AWS_SECRET_ACCESS_KEY="$awssecretaccesskey" fi +if [ "`echo $desturl | /usr/bin/awk -F ':' '{print $1}'`" == "cf+http" ]; then + export CLOUDFILES_USERNAME="$cfusername" + export CLOUDFILES_APIKEY="$cfapikey" + if [ -n "$cfauthurl" ]; then + export CLOUDFILES_AUTHURL="$cfauthurl" + fi +fi + ### Cleanup commands (duplicity >= 0.4.4) # cleanup