Skip to content

Instantly share code, notes, and snippets.

@melehin
Created September 30, 2021 12:16
Show Gist options
  • Save melehin/2ed356798886d14c9002da03993e6c6c to your computer and use it in GitHub Desktop.
Save melehin/2ed356798886d14c9002da03993e6c6c to your computer and use it in GitHub Desktop.
How to create Python executable with dependencies inside one file (statically linked, linux)
pip3 install pyinstall staticx
pyinstall --onefile script.py
# Static executable with deps
staticx dist/script dist/script.static
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment