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

Docker - Building with volume mapping to the workspace fails on errors #1

Open
rdar-lab opened this issue Dec 1, 2020 · 2 comments

Comments

@rdar-lab
Copy link
Owner

rdar-lab commented Dec 1, 2020

When using a local volume to map to the workdir, the bake command fails on errors on creating hard-links:

Exception: subprocess.CalledProcessError: Command 'cp -afl --preserve=xattr ./* /home/build/workspace/build/tmp/sysroots/qemux86' returned non-zero exit status 1

Subprocess output:
cp: cannot create hard link '/home/build/workspace/build/tmp/sysroots/qemux86/lib/libudev.so.1' to './lib/libudev.so.1': Input/output error
cp: cannot create hard link '/home/build/workspace/build/tmp/sysroots/qemux86/usr/lib/libudev.so' to './usr/lib/libudev.so': Input/output error

@rdar-lab
Copy link
Owner Author

rdar-lab commented Dec 6, 2020

As a workaround:

  1. Do not map the volume with the source code to the container, instead:
    a. Create a persistent docker container with a specific name
    b. Copy the source files to the /home/build/workspace directory (using the docker cp command for example)
    c. Start the build process
    d. If needed copy back the artifacts of the build (Again using docker cp command)
    e. Remove the container

@rdar-lab
Copy link
Owner Author

This does not happen when using local volume mapping to the 'tmp' directory. The README.md file was updated with the necessary steps.

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

No branches or pull requests

1 participant