mirror of
https://github.com/processone/ejabberd
synced 2025-10-06 03:50:15 +02:00
Update Dockerfile
Dockerfile: add Python & psycopg2 support for external auth scripts This change installs python3, pip, and required build deps in both build and runtime stages, and globally installs bcrypt and psycopg2. Motivation: - ejabberd supports external authentication scripts written in Python. - These scripts often require bcrypt (password hashing) and psycopg2 (PostgreSQL driver). - Currently, users need to extend the official image to add these dependencies manually. With this change, the official Docker image can run Python auth scripts out of the box.
This commit is contained in:
parent
ff3d33dde4
commit
b720143cae
1 changed files with 17 additions and 0 deletions
17
.github/container/Dockerfile
vendored
17
.github/container/Dockerfile
vendored
|
@ -19,6 +19,11 @@ RUN go install -v \
|
|||
FROM docker.io/erlang:${OTP_VSN}-alpine AS ejabberd
|
||||
|
||||
RUN apk -U add --no-cache \
|
||||
python3 \
|
||||
py3-pip \
|
||||
build-base \
|
||||
postgresql-dev \
|
||||
python3-dev \
|
||||
autoconf \
|
||||
automake \
|
||||
bash \
|
||||
|
@ -37,6 +42,9 @@ RUN apk -U add --no-cache \
|
|||
yaml-dev \
|
||||
zlib-dev
|
||||
|
||||
# Install Python packages globally
|
||||
RUN pip3 install --no-cache-dir --break-system-packages bcrypt psycopg2
|
||||
|
||||
ARG ELIXIR_VSN
|
||||
RUN wget -O - https://github.com/elixir-lang/elixir/archive/v$ELIXIR_VSN.tar.gz \
|
||||
| tar -xzf -
|
||||
|
@ -171,6 +179,15 @@ RUN apk -U upgrade --available --no-cache \
|
|||
&& rm /tmp/runDeps \
|
||||
&& ln -fs /usr/lib/libtdsodbc.so.0 /usr/lib/libtdsodbc.so
|
||||
|
||||
RUN apk -U add --no-cache \
|
||||
python3 \
|
||||
py3-pip \
|
||||
build-base \
|
||||
postgresql-dev \
|
||||
python3-dev
|
||||
# Install Python packages globally
|
||||
RUN pip3 install --no-cache-dir --break-system-packages bcrypt psycopg2
|
||||
|
||||
ARG USER
|
||||
ARG UID
|
||||
ARG HOME
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue