-
Notifications
You must be signed in to change notification settings - Fork 248
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
Refactoring the Linux build script #99
Comments
I must admit, I'm quite drawn to (2), since that could make the code quite similar to the macOS and windows builds, keeping the control flow in a single python process. We'd wrap up the def call(args, env):
subprocess.check_call(['docker', 'exec', '--env', env, container_id] + args) Then, once the container is set up and running, it's just lots of commands like call(['pip', 'wheel', project_dir, '-w', '/tmp/built_wheel', '--no-deps'], env=env) I'm sure it's a bit more complicated than that (the macOS and Windows builds stuff like |
You could use https://docs.docker.com/engine/reference/run/#env-environment-variables For setting env var you can (1) |
The piped bash script was removed in #386 - replaced with a system similar to (2) above, but using a shell process and open pipes instead of |
Currently the linux build works by piping a bash script into /bin/bash inside the docker container.
A couple good ideas have come out of the discussion in #97, so I wanted to keep them in an open issue!
@altendky: maybe a good way would be a Python script with a CLI (probably small enough to comfortably do with stdlib and 2/3 compatibility) and we pass in the info via the command. No config file to write and copy, no template to fill out. Just copy the exact Python script over to the container and then docker run it with proper arguments.
@altendky: Or, maybe we just replace the string/file with python code calling docker run for each command?
The text was updated successfully, but these errors were encountered: