Guest User

Untitled

a guest
Oct 21st, 2017
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.97 KB | None | 0 0
  1. .PHONY: backup
  2. backup: mount
  3. @export id="`novacom -w run file://bin/cat -- /proc/nduid | cut -c 1-8`" ; \
  4. mkdir -p clones/$$id ; \
  5. echo "Creating clones/$$id/tokens.txt" ; \
  6. novacom -w run file://sbin/tokens -- --list > clones/$$id/tokens.txt ; \
  7. echo "Creating clones/$$id/${CUSTIMAGEOLD}.nvram.bin" ; \
  8. ( novacom -w run file://bin/dd -- if=/dev/${NVRAM_PARTITION} ) > \
  9. clones/$$id/${CUSTIMAGEOLD}.nvram.bin ; \
  10. echo "Creating clones/$$id/${CUSTIMAGEOLD}.varfs.tar.gz" ; \
  11. ( novacom -w run file://bin/tar -- -C /tmp/var/ --totals -cf - . ) | \
  12. gzip -c > clones/$$id/${CUSTIMAGEOLD}.varfs.tar.gz ; \
  13. echo "Creating clones/$$id/${CUSTIMAGEOLD}.rootfs.tar.gz" ; \
  14. ( novacom -w run file://bin/tar -- -C /tmp/root/ --totals -cf - . ) | \
  15. gzip -c > clones/$$id/${CUSTIMAGEOLD}.rootfs.tar.gz ; \
  16. echo "Creating clones/$$id/${CUSTIMAGEOLD}.boot.tar.gz" ; \
  17. ( novacom -w run file://bin/tar -- -C /tmp/boot/ --totals -cf - . ) | \
  18. gzip -c > clones/$$id/${CUSTIMAGEOLD}.boot.tar.gz ; \
  19. echo "Creating clones/$$id/${CUSTIMAGEOLD}.mojodb.tar.gz" ; \
  20. ( novacom -w run file://bin/tar -- -C /tmp/mojodb/ --totals -cf - . ) | \
  21. gzip -c > clones/$$id/${CUSTIMAGEOLD}.mojodb.tar.gz ; \
  22. echo "Creating clones/$$id/${CUSTIMAGEOLD}.filecache.tar.gz" ; \
  23. ( novacom -w run file://bin/tar -- -C /tmp/filecache/ --totals -cf - . ) | \
  24. gzip -c > clones/$$id/${CUSTIMAGEOLD}.filecache.tar.gz ; \
  25. echo "Creating clones/$$id/${CUSTIMAGEOLD}.log.tar.gz" ; \
  26. ( novacom -w run file://bin/tar -- -C /tmp/log/ --totals -cf - . ) | \
  27. gzip -c > clones/$$id/${CUSTIMAGEOLD}.log.tar.gz ; \
  28. echo "Creating clones/$$id/${CUSTIMAGEOLD}.update.tar.gz" ; \
  29. ( novacom -w run file://bin/tar -- -C /tmp/update/ --totals -cf - . ) | \
  30. gzip -c > clones/$$id/${CUSTIMAGEOLD}.update.tar.gz ; \
  31. echo "Creating clones/$$id/${CUSTIMAGEOLD}.media.tar.gz" ; \
  32. ( novacom -w run file://bin/tar -- -C /tmp/media/ --totals -cf - . ) | \
  33. gzip -c > clones/$$id/${CUSTIMAGEOLD}.media.tar.gz ; \
Add Comment
Please, Sign In to add comment