diff options
-rwxr-xr-x | ezjail-admin | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ezjail-admin b/ezjail-admin index da65082..443ee09 100755 --- a/ezjail-admin +++ b/ezjail-admin | |||
@@ -951,6 +951,13 @@ restore) | |||
951 | [ "${ezjail_hsname}" != "${ezjail_nameprop_hsname}" ] && exerr "Error: Archive was created on host named ${ezjail_hsname}. Can only use restore on the same machine. Consider using \"ezjail-admin create -a\" when migrating ezjails." | 951 | [ "${ezjail_hsname}" != "${ezjail_nameprop_hsname}" ] && exerr "Error: Archive was created on host named ${ezjail_hsname}. Can only use restore on the same machine. Consider using \"ezjail-admin create -a\" when migrating ezjails." |
952 | [ "${ezjail_hscpu}" != "${ezjail_nameprop_hscpu}" ] && exerr "Error: Archive was created on a different CPU. Can not restore. Consider using \"ezjail-admin create -a\" when migrating ezjails." | 952 | [ "${ezjail_hscpu}" != "${ezjail_nameprop_hscpu}" ] && exerr "Error: Archive was created on a different CPU. Can not restore. Consider using \"ezjail-admin create -a\" when migrating ezjails." |
953 | 953 | ||
954 | # Save config to tempfile and source it | ||
955 | tmpfile=`mktemp /tmp/ezjail.prop.XXXXXXXX` | ||
956 | [ $? -ne 0 ] && exerr "Error: Can't create temporary file." | ||
957 | pax -rzn -s:${ezjail_nameprop}:${tmpfile}: -f ${ezjail_fromarchive} ${ezjail_nameprop} | ||
958 | . "${tmpfile}" | ||
959 | rm -f "${tmpfile}" | ||
960 | |||
954 | shift 1 | 961 | shift 1 |
955 | done | 962 | done |
956 | ;; | 963 | ;; |