.\n\nCreate a file called rclone.conf with following content:\n\n```\n[swift-remote]\ntype = swift\nuser = $OS_USERNAME\nkey = $OS_PASSWORD\nauth = $OS_AUTH_URL\ndomain = default\ntenant = $OS_TENANT_NAME\n```\n\n\nWhen we want to refer to Swift we will now use 'swift-remote:' and rclone will handle auth for us (assuming openrc has been sourced first).\n\nCreate a container in Swift:\n\n`rclone --config rclone.conf mkdir swift-remote:pg_backup`\n\n\nUpload db dump to pg_backup container:\n\n`rclone --config rclone.conf copy mydb.sql swift-remote:pg_backup`\n\n\nDefault behaviour is to copy entire directory contents unless source is a file.\n\n~~At the time of writing (2017-04-07) the current version of rclone (v1.36) does not support expiration header for Swift. It's scheduled for v1.37 ([Github issue #59](https://github.com/ncw/rclone/issues/59)) or later. Meanwhile you can delete old files with:~~\n\n`rclone --config rclone.config --min-age 1h delete swift-remote:pg_backup/`\n\nUpdate 2020-11-16: Since [v1.52](https://rclone.org/changelog/#v1-52-0-2020-05-27) rclone support sending additonal headers, so you can now set expiration date on file uploads:\n\n`rclone --config rclone.conf --header-upload \"X-Delete-After: 3600\" copy mydb.sql swift-remote:pg_backup`\n\n\n## Summary\n\n\nThat's it! My personal recommendation is to use python-swiftclient or OpenStack CLI client (not shown in examples) where available. Both are maintained by the OpenStack community and are the most supported software out there.\n\nRclone can be useful if you use more than one cloud storage platform, or at least want the possibility to be able to. Rclone is the cloud equivalent to rsync, a software known to be excellent when it comes to copy large amounts of data and files.\n\ncURL can be run almost anywhere (it even works on AmigaOS, DOS and OS/2!) but require more knowledge of Swift REST API.\n\nIf you have any questions or want to know more about how OpenStack can help your company contact me or a colleague and we'll be in touch!\n \n\nAndreas Holmsten"}],"slug":"getting-started-with-application-backups-to-swift","url":"/se/news/getting-started-with-application-backups-to-swift","lang":"se","filename":"getting-started-with-application-backups-to-swift"}],"lang":"se","title":"Swift","hero_image":{"src":"/assets/uploads/hero-background.jpg"},"slug":"swift","fileName":"swift","metaTags":{"ogImage":null,"title":"Swift"},"footerData":{"se":{"contact":{"title":"Kontakt","address_1":"Elastx c/o Convendum\nKungsgatan 9\n","address_2":"111 43 Stockholm","rows":[{"row":"VAT: SE556906561701"},{"row":"Telefon: [+46 8 557 728 10](tel:+46855772810)"},{"row":"Epost: [info@elastx.se](mailto:info@elastx.se)"}]},"links":{"title":"Länkar","extra_footer_links":[{"targetBlank":true,"label":"Karriär","link":"https://career.elastx.se/"}]},"social":{"title":"Sociala kanaler","links":[{"label":"LinkedIn","url":"https://www.linkedin.com/company/elastx"},{"label":"YouTube","url":"https://www.youtube.com/@Elastx"}]},"cert_logos":{"logos":[{"logo":"/assets/uploads/iso-27001-1.png","link":"/information-security-policy"},{"logo":"/assets/uploads/iso-14001-1.png","link":"/environment-policy"}]},"external_cert_logos":{"logos":[{"logo":"/assets/uploads/green-web-foundation.png","link":"https://www.thegreenwebfoundation.org/green-web-check/?url=elastx.se"}]},"menulinks":[{"label":"Hem","link":"/"},{"label":"Om oss","link":"/about-elastx"},{"label":"Kontakt","link":"/contact-us"},{"label":"Tjänster","link":"/overview"},{"label":"Priser","link":"/pricing"},{"label":"Partners","link":"/partners"},{"label":"Nyheter","link":"/news"},{"label":"Events","link":"/events"}]},"en":{"contact":{"title":"Contact","rows":[{"row":"VAT: SE556906561701"},{"row":"Phone: [+46 8 557 728 10](tel:+46855772810)"},{"row":"Email: [info@elastx.se](mailto:info@elastx.se)"}],"address_1":"Elastx c/o Convendum\nKungsgatan 9\n","address_2":"111 43 Stockholm"},"links":{"title":"Links","extra_footer_links":[{"targetBlank":true,"label":"Career","link":"https://career.elastx.se/"}]},"social":{"title":"Social channels","links":[{"label":"LinkedIn","url":"https://www.linkedin.com/company/elastx"},{"label":"YouTube","url":"https://www.youtube.com/@Elastx"}]},"external_cert_logos":{"logos":[{"logo":"/assets/uploads/green-web-foundation.png","link":"https://www.thegreenwebfoundation.org/green-web-check/?url=elastx.se"}]},"cert_logos":{"logos":[{"logo":"/assets/uploads/iso-27001-1.png","link":"/information-security-policy"},{"logo":"/assets/uploads/iso-14001-1.png","link":"/environment-policy"}]},"menulinks":[{"label":"Home","link":"/"},{"label":"About us","link":"/about-elastx"},{"label":"Contact","link":"/contact-us"},{"label":"Services","link":"/overview"},{"label":"Pricing","link":"/pricing"},{"label":"Partners","link":"/partners"},{"label":"News","link":"/news"},{"label":"Events","link":"/events"}]}}}