Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

Commit

Permalink
fix: install pkg-config dependency for mysqlclient>=2.2.0
Browse files Browse the repository at this point in the history
Repositiories that depend on mysqlclient>=2.2.0 will need to install the package pkg-config in their Dockerfile: PyMySQL/mysqlclient#620. This commit installs the pkg-config package in the Dockerfile.

If this is missing, then pip install of mysqlclient fails with an error that includes the following:

Exception: Can not find valid pkg-config name.
Specify MYSQLCLIENT_CFLAGS and MYSQLCLIENT_LDFLAGS env vars manually

See edx/edx-arch-experiments#349.
  • Loading branch information
MichaelRoytman committed Jul 6, 2023
1 parent 566dfb7 commit ba2882c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
FROM ubuntu:focal as base

# System requirements.

# pkg-config; mysqlclient>=2.2.0 requires pkg-config (https://github.com/PyMySQL/mysqlclient/issues/620)

RUN apt update && \
apt-get install -qy \
DEBIAN_FRONTEND=noninteractive apt-get install -qy \
curl \
vim \
language-pack-en \
Expand All @@ -11,6 +14,7 @@ RUN apt update && \
python3-virtualenv \
python3.8-distutils \
libmysqlclient-dev \
pkg-config \
libssl-dev && \
rm -rf /var/lib/apt/lists/*

Expand Down

0 comments on commit ba2882c

Please sign in to comment.