Skip to content

Commit

Permalink
dev_cli.sh: Fix kvm directory path of the build command
Browse files Browse the repository at this point in the history
Current local variable `exported_device` under `cmd_build()`
misses the root directory in the beginning, which will lead to
the error of:

```
docker: Error response from daemon: OCI runtime create failed:
invalid mount {Destination:dev/kvm Type:bind
[...]
Options:[rbind]}: mount destination dev/kvm not absolute: unknown.
```
when running `scripts/dev_cli.sh build` command.

Fix the path by following the `cmd_test()`.

Signed-off-by: Henry Wang <[email protected]>
  • Loading branch information
MrXinWang authored and rbradford committed Mar 29, 2023
1 parent 0a2e604 commit 0ddfc6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/dev_cli.sh
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ cmd_build() {
arch="$(uname -m)"
build="debug"
features_build=""
exported_device="dev/kvm"
exported_device="/dev/kvm"
while [ $# -gt 0 ]; do
case "$1" in
"-h"|"--help") { cmd_help; exit 1; } ;;
Expand Down

0 comments on commit 0ddfc6d

Please sign in to comment.