mybin

my ~/bin
git clone https://a3nm.net/git/mybin/
Log | Files | Refs | README

luks_umount (212B)


      1 #!/bin/bash
      2 
      3 VOLUME="$1"
      4 MACHINE="$2"
      5 if [ -z $MACHINE ]
      6 then
      7   COMMAND=""
      8 else
      9   COMMAND="ssh $MACHINE"
     10 fi
     11 MOUNTPOINT="/mnt/$VOLUME"
     12 
     13 $COMMAND sudo umount "$MOUNTPOINT"
     14 $COMMAND sudo cryptsetup close "$VOLUME"
     15