13

I have some python application that should run on customer site. I compile my py files to pyc (python byte code).

What is the standard way to run the app on the customer environment? The options I see are:

  • As part of my installer, install some python distribution, i.e Anaconda.
  • Require the customer to have python installed in their environment.
  • Bring python libraries and executable along with my code and run it directly from my installation dir.
  • Convert the scripts to exe using some py-to-exe tool.

Application usage: The app is used as a tool to calculate statistics for my main product. The customer won't run it explicitly. It won't have any GUI.

Customer environment will be x64 Windows machine. No other restrictions.

Any recommendations or comments? I couldn't find such discussions on the web.

2
  • since you mention anaconda, do you rely on specific conda packages being installed? also is this supposed to be a server application i.e. something that has a remote API of some sort? Commented Sep 6, 2016 at 15:56
  • I think the proper solution now days would be to package the app in a docker image Commented Apr 11, 2021 at 7:19

1 Answer 1

3

Given your requirements, the last two options seem most viable:

  • Bring python libraries and executable along with my code and run it directly from my installation dir.
  • Convert the scripts to exe using some py-to-exe tool.

You can either package your code, or freeze your code and create an executable for the target OS.

Given your requirements, I'd suggest the latter. You can go through the Python Packaging Guide for more details regarding packaging.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.