mirror of
/repos/dotTiddlywiki.git
synced 2025-12-30 07:31:33 +01:00
60 lines
1.4 KiB
Plaintext
60 lines
1.4 KiB
Plaintext
created: 20150511071117085
|
|
creator: user
|
|
modified: 20160830195726481
|
|
modifier: user
|
|
tags:
|
|
title: use usb stick with docker
|
|
type: text/vnd.tiddlywiki
|
|
|
|
move current pi stuff
|
|
|
|
```bash
|
|
rsync -aSHAXP --info=progress2 --delete /mnt /home/pi
|
|
```
|
|
|
|
moving existing docker graph
|
|
|
|
```bash
|
|
rsync -aSHAXP --info=progress2 --delete /var/lib/docker /mnt/usb
|
|
```
|
|
|
|
; Full system backup with rsync
|
|
: https://wiki.archlinux.org/index.php/full_system_backup_with_rsync
|
|
|
|
```bash
|
|
mke2fs -T ext4,news -L docker -v /dev/sda
|
|
```
|
|
|
|
$ cat /etc/default/docker
|
|
|
|
```sh
|
|
# Docker Upstart and SysVinit configuration file
|
|
|
|
# Customize location of Docker binary (especially for development testing).
|
|
#DOCKER="/usr/local/bin/docker"
|
|
|
|
# Use DOCKER_OPTS to modify the daemon startup options.
|
|
#DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4"
|
|
DOCKER_OPTS="--storage-driver=overlay -D --graph=/mnt/usb/docker"
|
|
#DOCKER_OPTS="--storage-driver=overlay -D"
|
|
|
|
# If you need Docker to use an HTTP proxy, it can also be specified here.
|
|
export http_proxy="http://192.168.2.1:3128/"
|
|
|
|
# This is also a handy place to tweak where Docker's temporary files go.
|
|
#export TMPDIR="/mnt/bigdrive/docker-tmp"
|
|
export TMPDIR="/mnt/usb/docker-tmp"
|
|
```
|
|
|
|
```bash
|
|
mkdir -p /mnt/usb/docker /mnt/usb/docker-tmp
|
|
```
|
|
$ ls -lathr /dev/disk/by-uuid/
|
|
|
|
```
|
|
$ cat /etc/fstab
|
|
|
|
proc /proc proc defaults 0 0
|
|
/dev/mmcblk0p1 /boot vfat defaults 0 0
|
|
UUID=16e0972d-6abf-4369-be0e-5fd2e10a070a /mnt/usb ext4 commit=600,noatime 0 0
|
|
``` |