summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMürsel Türk2022-10-04 19:45:06 +0200
committerMürsel Türk2022-10-04 19:45:06 +0200
commit4caa5f6b08cc54705b0a7526880e87a042a6743c (patch)
treeb7317488026be58bd86ed54d1674cf9a86dfe12c
parentAdd support for gentoo linux (diff)
downloadvm-inspector-4caa5f6b08cc54705b0a7526880e87a042a6743c.tar.gz
vm-inspector-4caa5f6b08cc54705b0a7526880e87a042a6743c.tar.xz
vm-inspector-4caa5f6b08cc54705b0a7526880e87a042a6743c.zip
Use auto-detecting instead of forcing the format
-rw-r--r--README.md13
-rw-r--r--tools/nbdfuse.py7
2 files changed, 12 insertions, 8 deletions
diff --git a/README.md b/README.md
index 04587d0..53dc3b2 100644
--- a/README.md
+++ b/README.md
@@ -1,12 +1,17 @@
-# vmdk-inspector
-A (work-in-progress) Tool for examining a VMDK disk image to determine which operating system and applications it contains.
+# vm-inspector
+
+A sample tool for inspecting a disk image file, e.g. vmdk, vdi, qcow, etc., to determine which operating system and applications it contains.
## Usage
-To inspect a VMDK disk image:
+
+To inspect a disk image file:
+
```
python3 inspect.py foo.vmdk
```
+
or
+
```
./inspect.py foo.vmdk
-``` \ No newline at end of file
+```
diff --git a/tools/nbdfuse.py b/tools/nbdfuse.py
index b7a4997..09591ea 100644
--- a/tools/nbdfuse.py
+++ b/tools/nbdfuse.py
@@ -13,8 +13,8 @@ L = logging.getLogger(__name__)
@log
def mount(path):
- """Mount a VMware Virtual Machine Disk (VMDK) file as a RAW image file in
- the local filesystem with read-only support using `qemu-nbd` + `nbdfuse`.
+ """Mount a disk image file as a RAW image file in the local filesystem with
+ read-only support using `qemu-nbd` + `nbdfuse`.
See also:
https://manpages.debian.org/bullseye/qemu-utils/qemu-nbd.8.en.html
@@ -24,7 +24,7 @@ def mount(path):
$ sudo apt install qemu-utils nbdfuse
Args:
- path (str): Path to the VMDK file.
+ path (str): Path to the disk image file.
Returns:
Path to the directory containing a single virtual file named `nbd`.
@@ -37,7 +37,6 @@ def mount(path):
"--socket-activation",
"qemu-nbd",
"--read-only",
- "--format=vmdk",
path
]