promptflow icon indicating copy to clipboard operation
promptflow copied to clipboard

[Feature Request] Make Docker Python version configurable

Open adam-lagoda opened this issue 1 year ago • 2 comments

Is your feature request related to a problem? Please describe. When building a Docker image for the flow using pf flow build --source ./flows/standard --output dist --format docker the resulting Dockerfile contains RUN conda create -n promptflow-serve python=3.9.16 [..] by default.

It would be great if the python version of the deployment would be configurable. The template for the Dockerfile can be found here src/promptflow-devkit/promptflow/_sdk/data/docker/Dockerfile.jinja2

Describe the solution you'd like I would like the python version to be configurable by a flag. If a flag is missing, then the version and fall to a default 3.9.16 as is now,

Describe alternatives you've considered The python version for the Dockerfile conda environment could be parsable from the active environment that is used for the build. If, if I run pf flow build [...] from my conda env with python 3.12.4, I would like to see RUN conda create -n promptflow-serve python=3.12.4 [..] in the Dockerfile

Additional context Add any other context or screenshots about the feature request here.

adam-lagoda avatar Jan 23 '25 08:01 adam-lagoda

@adam-lagoda I thought about this as well and came up with just building the things myself. If you are still looking for a solution you might like to look at this small starter which uses a devcontainer, python 3.12, fastapi and docker. promptflow-starter-template

You can easily package and build it yourself in a versioned way, too.

FabianSchurig avatar Feb 15 '25 16:02 FabianSchurig

Hi, we're sending this friendly reminder because we haven't heard back from you in 30 days. We need more information about this issue to help address it. Please be sure to give us your input. If we don't hear back from you within 7 days of this comment, the issue will be automatically closed. Thank you!

github-actions[bot] avatar Mar 17 '25 21:03 github-actions[bot]