You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

12345678910111213141516171819
  1. #! /bin/bash
  2. #
  3. set -o allexport;
  4. source ./.env;
  5. set +o allexport
  6. volume_path=/home/$USER/.docker-data/volumes
  7. # volume_path=/var/lib/docker/volumes
  8. volume_src_path=$volume_path/$PREFIX-web/_data
  9. volume_dest_path=$PWD/volume
  10. if [ -d ./volume ]; then
  11. if [ ! "$(ls -A ./volume)" ]; then
  12. /usr/bin/bindfs --force-user=$USER --force-group=$USER --create-for-user=www-data --create-for-group=www-data $volume_src_path $volume_dest_path
  13. fi
  14. fi