Skip to content

Commit

Permalink
Merge pull request #310 from firesim/abejgonzalez-patch-4
Browse files Browse the repository at this point in the history
Fix mounting for Ubuntu 22.x machines
  • Loading branch information
abejgonzalez authored Aug 29, 2024
2 parents 74ac78a + 8cea603 commit b51cc3e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wlutil/wlutil.py
Original file line number Diff line number Diff line change
Expand Up @@ -595,7 +595,8 @@ def mountImg(imgPath, mntPath):

assert imgPath.is_file(), f"Unable to find {imgPath} to mount"
ret = run(["mountpoint", mntPath], check=False).returncode
assert ret == 1, f"{mntPath} already mounted. Somethings wrong"
# mountpoint on Ubuntu 20.* returns 1 (on 22.* it returns 32) for an empty folder
assert ret == 1 or ret == 32, f"{mntPath} already mounted. Somethings wrong"

uid = sp.run(['id', '-u'], capture_output=True, text=True).stdout.strip()
gid = sp.run(['id', '-g'], capture_output=True, text=True).stdout.strip()
Expand Down

0 comments on commit b51cc3e

Please sign in to comment.