我正在尝试为flask应用程序构建一个docker镜像,它需要pymssql来连接到sql server。在requirements.txt文件中指定pymssql=2.2.5,并尝试构建镜像。
我试过docker build -t <image-name> .
Collecting pymssql==2.2.5
#9 23.25 Downloading pymssql-2.2.5.tar.gz (170 kB)
#9 23.27 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 170.1/170.1 KB 9.9 MB/s eta 0:00:00
#9 23.38 Installing build dependencies: started
#9 27.65 Installing build dependencies: finished with status 'done'
#9 27.65 Getting requirements to build wheel: started
#9 27.90 Getting requirements to build wheel: finished with status 'error'
#9 27.90 error: subprocess-exited-with-error
#9 27.90
#9 27.90 × Getting requirements to build wheel did not run successfully.
#9 27.90 │ exit code: 1
#9 27.90 ╰─> [6 lines of output]
#9 27.90 setup.py: platform.system() => Linux
#9 27.90 setup.py: platform.architecture() => ('64bit', '')
#9 27.90 setup.py: platform.libc_ver() => ('glibc', '2.31')
#9 27.90 setup.py: include_dirs => []
#9 27.90 setup.py: library_dirs => []
#9 27.90 setup.py: could not locate 'clock_gettime' function required by FreeTDS.
#9 27.90 [end of output]
#9 27.90
#9 27.90 note: This error originates from a subprocess, and is likely not a problem with pip.
#9 27.90 error: subprocess-exited-with-error
字符串
1条答案
按热度按时间h9vpoimq1#
在Debian上,你需要安装freetds-dev g++
字符串