Files¶
Listing Files¶
Fru.io list can list different types of objects including backups, databases, execs, files, restores, and sites.
The following command returns the file assets for the mysite site. In this example, there is one file named foo.jpg in your files directory.
$ Fru.io list files mysite
FILE ASSETS
PATH
foo.jpg
File Backups¶
File backups are created on demand and are not run on a schedule. Once a backup has been generated it can be restored to a site.
Fru.io backup initiates a job to create a backup of files. The output will contain a job name you can use to get more information.
$ Fru.io backup files mysite
Initiated files backup: Fru-demo/mysite-d6m5h
Fru.io describe will give you the job's status.$ Fru.io describe backup file Fru-demo/mysite-d6m5h
Name: mysite-d6m5h
Org: Fru-demo
Created: 29s ago (2020-04-23 17:33:41 -0400 EDT)
FileStore: mysite
Type: export
Status: Completed
File Restores¶
Fru.io restore files initiates a job to create a backup of files. The output will contain a job name you can use to get more information.
$ Fru.io restore files mysite
Initiated files restore Fru-demo/mysite-wtm5z
Fru.io describe will give you the job's status.$ Fru.io describe restore files Fru-demo/mysite-wtm5z
Name: mysite-wtm5z
Org: Fru-demo
Created: 20s ago (2020-04-23 18:39:38 -0400 EDT)
FileStore: mysite
Type: import
Status: Completed
Pushing Files¶
Fru.io push can move files and databases from your local environment to a site.
The following command pushes a file named foo.jpg from local to live.
$ Fru.io push files mysite foo.jpg
Uploaded: foo.jpg
To: backups/on-demand/foo.jpg
Pulling Files¶
Fru.io pull can move files and databases from a site to your local environment.
The following command downloads a file named foo.jpg from the mysite site to the current local working directory.
$ Fru.io pull files mysite foo.jpg
Asset(s) downloaded.
The following command downloads all files from the
mysite site to the local /home/Fru-demo/tmp directory.
$ Fru.io pull files mysite --dest ~/tmp
trimmed: foo.jpg
localDestPath /home/Fru-demo/tmp/foo.jpg
Downloaded foo.jpg (1/2)
trimmed: bar.jpg
localDestPath /home/Fru-demo/tmp/bar.jpg
Downloaded bar.jpg (2/2)
Asset(s) downloaded.