Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improvements to set_xva_bridge.sh #267

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

dinhngtu
Copy link
Member

@dinhngtu dinhngtu commented Jan 10, 2025

This PR introduces a few improvements to set_xva_bridge.sh:

  • Fix cases where XVA_NAME contains spaces
  • Get TMP_LIST from original archive instead of sorting to avoid situations where sort doesn't put ova.xml in the correct order
  • Set owner and permissions in tar command instead of using sudo to read unreadable files
  • Use file -b to simplify filetype parsing
  • Don't check existing bridge name to avoid unnecessary tar pass

Tu Dinh added 5 commits January 10, 2025 17:59
ova.xml must come first in the archive order. sort sometimes fails to do
this correctly even if LC_ALL is set to "C". Fix this by taking the
original file list from tar instead.

Signed-off-by: Tu Dinh <[email protected]>
Erase the output archive members' owner and permissions directly through
tar command line.  Make extracted temp files readable with chmod to
avoid using sudo for reading input files.

Signed-off-by: Tu Dinh <[email protected]>
file -b avoids printing filename in file's output, which simplifies
filetype parsing a bit.

Signed-off-by: Tu Dinh <[email protected]>
Bridge name can be checked through get_xva_bridge, no need to spend
another pass on the XVA file for this.

Signed-off-by: Tu Dinh <[email protected]>
@stormi stormi requested a review from gduperrey January 13, 2025 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants