R
Railway4mo ago
patrgl

Attempting to run mysqldump with the subprocess module in Python on a chronjob

Hey guys, I am attempting to run what is mentioned above but i get the following error in the deploy log: line 1: mysqldump: command not found I do have PyMySQL installed, i have tried the solutions listed here: https://www.answeroverflow.com/m/1133956338867773470, including placing this: [phases.setup] aptPkgs = ["...", "libmysqlclient-dev"] into a nixpackages.toml in my root directory to no avail.
Issue installing mysqlclient for FastAPI app - Railway
While building my app it's currently failing to install mysqlclient. I'm using nixpacks and I just updated the NIXPACKS_PYTHON_VERSION env var to use 3.11 which is the same as I'm running locally in my venv. I'm new to railway (and python apps) so i'd appreciate any tips on how to get the requirements to install and build successfully. I've atta...
Solution:
their issue was needing header files for the mysql client library, you simply need the mysqldump binary. try adding this nixpacks.toml file to your build - ```toml [phases.setup]...
Jump to solution
5 Replies
Percy
Percy4mo ago
Project ID: e828cf35-b85e-4ca4-99e2-1f686f8e5e01
patrgl
patrglOP4mo ago
e828cf35-b85e-4ca4-99e2-1f686f8e5e01
Solution
Brody
Brody4mo ago
their issue was needing header files for the mysql client library, you simply need the mysqldump binary. try adding this nixpacks.toml file to your build -
[phases.setup]
nixPkgs = ['...', 'mysql']
[phases.setup]
nixPkgs = ['...', 'mysql']
patrgl
patrglOP4mo ago
It worked! Thank you so much!!
Brody
Brody4mo ago
awsome!
Want results from more Discord servers?
Add your server