Bind mounts
Bind mounts allow binding a file or a directory and its contents from the parent host into an enclave. This page describes the steps required to setup a bind mount.
Set up the bind mount on the parent host. Using this example, we can bind the directory /home to the enclave:
# Set /home as the root bind directory anjuna-fs-proxy --daemonize --anjunafs-rootdir /home # Create a directory _enclave-data_ that we will bind to the enclave mkdir -p /home/enclave-data
Create an enclave configuration file with that bind mount:
version: 1.5 # define volume mounts for this enclave mounts: # name of the bind mapping # host must include a file or directory with the same name inside rootdir - name: enclave-data # 'basic' is the bind mount type type: basic # path to mount to inside the enclave mountPath: /shared/enclave-data
Using this example, the host mounted the directory /home/enclave-data to /shared/enclave-data inside the enclave.