Downloading files

How to download files in Cased Shell.
Downloading a file in Cased Shell is simple - it only takes two steps.
Downloading files with Cased Shell.
Once a user is in the host or container of their liking, the user must click the "Download a File" button on the top right of the terminal interface.
Then the user must simply enter the file path and press download.
That's it! The file will be downloaded and will pop up in your browser's download bar.

Example of downloading presets through containers

With Jump, set a preDownloadCommand:
- provider: static
# This prompt provides easy access to a running container named 'utility' on the
# server.
name: utility container
jumpCommand: docker exec -it utility
# To allow users accessing this shell to download files from inside the container
# instead of from the server they are connected to, Cased Shell supports
# running a command on the server before downloading a file using the `preDownloadCommand`
# field.
# The tokens `{filepath}` and `{filename}` will be replaced with the path and basename
# of the file to download. The command is expected to output the full path to the file
# on the server to stdout. In this example, we create a directory, extract the file from
# the running container with `docker cp`, and then output the full path to the file.
preDownloadCommand: |
sh -c 'mkdir -p /tmp/cased-downloads; docker cp utitlity:{filepath} /tmp/cased-downloads/; echo /tmp/cased-downloads/{filename}'