Uploading with exporters
ortfo/db comes with built-in exporters that cover most use cases for uploading the generated database.json file somwhere:
Cloud service providers
ortfo/db supports uploading to many cloud service providers by leveraging rclone.
This allows us to support a wide range of cloud services, such as Google Drive, Dropbox, and many others.
See all supported services
This list is automatically generated from rclone's documentation.
- 1Fichier
- Akamai Netstorage
- Amazon S3 (or S3 compatible)
- Backblaze B2
- Box
- Citrix ShareFile
- Dropbox
- Enterprise File Fabric
- Google Cloud Storage
- Google Drive
- Google Photos
- HDFS
- HiDrive
- Internet Archive
- Jottacloud
- Koofr
- Linkbox
- Mail.ru Cloud
- Mega
- Memory
- Microsoft Azure Blob Storage
- Microsoft Azure Files Storage
- Microsoft OneDrive
- OpenDrive
- OpenStack Swift
- Oracle Object Storage
- pCloud
- PikPak
- premiumize.me
- put.io
- Proton Drive
- QingStor
- Quatrix by Maytech
- Seafile
- SFTP
- Sia
- SMB
- SugarSync
- Storj
- Uloz.to
- Uptobox
- WebDAV
- Yandex Disk
- Zoho WorkDrive
Setup
INFO
In the future, ortfo/db might support configuring the remotes by itself
- Install rclone from rclone.org
- Configure a remote with
rclone config
- Keep in mind the name you gave to the remote, you'll need it later
Configuration
yaml
exporters:
cloud:
# Path to the folder where you want to upload the database.json file
path: projects/
# Filename to copy in the folder as (no renaming by default)
name: my_database.json
# Name of the rclone remote(s)
# This is a list because you can tell ortfo/db to upload to multiple rclone remotes in one go.
remotes: [my_remote]
Web servers
SSH
You can upload the database file to a server via SSH using the ssh
exporter.
Configuration
yaml
exporters:
ssh:
ssh: user@host:/path/to/database.json
rsync: true # true to use rsync, false to use scp
(S)FTP
The ftp
exporter allows you to upload the generated database.json file to a remote server using the FTP protocol (or SFTP) protocol.
Configuration
yaml
exporters:
ftp:
username: your username
password: your password
host: the host of the server
path: the path to where the file should be uploaded
secure: true # true to use SFTP, false to use FTP
Git repositories
Use the git
exporter
Configuration
yaml
exporters:
git:
# URL to the Git repository
url:
# Commit message used
commit:
# Where to copy the database.json file in the repository
path: database.json
# Additional flags to pass to git commit
git_commit_flags: ""
# Additional flags to pass to git push
git_push_flags: ""
# Additional flags to pass to git clone
git_clone_flags: ""
# Additional flags to pass to git add
git_add_flags: ""