소스 검색

Merge pull request #18891 from HackToday/18872-fix-volume-cmd

Fix the restore data example
Sebastiaan van Stijn 9 년 전
부모
커밋
dcbd5e04b7
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      docs/userguide/dockervolumes.md

+ 1 - 1
docs/userguide/dockervolumes.md

@@ -263,7 +263,7 @@ elsewhere. Create a new container.
 
 Then un-tar the backup file in the new container's data volume.
 
-    $ docker run --rm --volumes-from dbstore2 -v $(pwd):/backup ubuntu bash -c "cd /dbdata && tar xvf /backup/backup.tar"
+    $ docker run --rm --volumes-from dbstore2 -v $(pwd):/backup ubuntu bash -c "cd /dbdata && tar xvf /backup/backup.tar --strip 1"
 
 You can use the techniques above to automate backup, migration and
 restore testing using your preferred tools.