rhythmic-glass-66959
07/27/2022, 1:36 PMpython_distribution (wheel) into a Dockerfile built by pants?rhythmic-glass-66959
07/27/2022, 1:42 PM./pants package, and placed in the context using the artifact's output_path field.
⦠The output_path defaults to the scheme <http://path.to|path.to>.directory/tgt_name.ext, e.g. src.python.helloworld/bin.pex.nutritious-minister-3808
07/27/2022, 1:44 PMCOPY <http://path.to|path.to>.directory/tgt_name.whl /opt/destination/directory .rhythmic-glass-66959
07/27/2022, 1:45 PMpython_distribution(
name="dist",
provides=python_artifact(
name="my_package",
version="0.1.0",
),
)rhythmic-glass-66959
07/27/2022, 1:46 PMCOPY <http://src.python.my|src.python.my>_package/dist.whl /tmp failed (file does not exist).nutritious-minister-3808
07/27/2022, 1:47 PMCOPY <http://src.python.my|src.python.my>_package/my-package-0.1.0.whl /tmprhythmic-glass-66959
07/27/2022, 1:48 PMrhythmic-glass-66959
07/27/2022, 1:50 PMnutritious-minister-3808
07/27/2022, 1:51 PM./pants package src/python:distnutritious-minister-3808
07/27/2022, 1:51 PM":dist" as a dependency on the docker_image target?rhythmic-glass-66959
07/27/2022, 1:52 PMrhythmic-glass-66959
07/27/2022, 1:54 PMdocker_image(
name="my_docker_image",
dependencies=[
...
"src/python/my_package:dist",
],
)rhythmic-glass-66959
07/27/2022, 1:58 PM./pants package src/python/my_package:dist
09:56:17.93 [INFO] Wrote dist/my_package-0.1.0-py3-none-any.whl
09:56:17.93 [INFO] Wrote dist/my_package-0.1.0.tar.gznutritious-minister-3808
07/27/2022, 1:59 PMCOPY my_package-0.1.0-py3-none-any.whl /tmp should do itnutritious-minister-3808
07/27/2022, 1:59 PMrhythmic-glass-66959
07/27/2022, 2:00 PMbitter-ability-32190
07/27/2022, 2:05 PMoutput_path field to python_distribution .rhythmic-glass-66959
07/27/2022, 2:05 PMpython_distribution doesn't follow the documented scheme...bitter-ability-32190
07/27/2022, 2:06 PM./pants package ... and inspect where it is located in the dist dir. That'll be reflected in the docker context
⢠Use ./pants --no-process-cleanup ... and inspect the sandbox created for the docker build process