Created
          April 19, 2019 17:44 
        
      - 
      
- 
        Save rms1000watt/a00b52aa192cfce7e6a5d693dcb5f18d to your computer and use it in GitHub Desktop. 
    Volume Mount AWS NVMe SSD and point docker to run from it
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | if [[ ${disk_ephemeral} -eq 1 ]]; then | |
| echo "START: Mount the ephemeral disk" | |
| sudo mkfs.ext4 /dev/nvme0n1 | |
| sudo mount -t ext4 /dev/nvme0n1 /opt | |
| echo '/dev/nvme0n1 /opt auto noatime 0 0' | sudo tee -a /etc/fstab | |
| sudo mount -a | |
| sudo chmod -R 777 /opt | |
| echo "DONE: Mount the ephemeral disk" | |
| mkdir -p /etc/docker | |
| echo '{"log-driver":"json-file","log-opts":{"max-size":"10m"},"data-root":"/opt/docker"}' > /etc/docker/daemon.json | |
| fi | |
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment