Skip to content

Commit

Permalink
Add pypi backends to setup.py as a convience when installing errbot. (e…
Browse files Browse the repository at this point in the history
  • Loading branch information
nzlosh authored and sijis committed Jan 1, 2024
1 parent 04d80e8 commit 6f664aa
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ features:

- core/plugins: detect plugins using entrypoints (#1590)
- core/logging: add new SENTRY_OPTIONS config (#1597)
- core/plugins: make slack, mattermost and discord backends available as install requirements (#1611)

fixes:

Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
ARG BASE_IMAGE=python:3.9-slim
ARG INSTALL_EXTRAS=irc,XMPP,telegram
ARG INSTALL_EXTRAS=irc,XMPP,telegram,slack

FROM ${BASE_IMAGE} AS build
ARG INSTALL_EXTRAS
WORKDIR /wheel
COPY . .
RUN apt update && apt install -y build-essential git
RUN pip3 wheel --wheel-dir=/wheel \
wheel . .[${INSTALL_EXTRAS}] errbot-backend-slackv3
wheel . .[${INSTALL_EXTRAS}]

FROM ${BASE_IMAGE} AS base
ARG INSTALL_EXTRAS
Expand All @@ -16,7 +16,7 @@ RUN apt update && \
apt install -y git && \
cd /wheel && \
pip3 -vv install --no-cache-dir --no-index --find-links /wheel \
errbot errbot[${INSTALL_EXTRAS}] errbot-backend-slackv3 && \
errbot errbot[${INSTALL_EXTRAS}] && \
rm -rf /wheel /var/lib/apt/lists/*
RUN useradd -m errbot

Expand Down
9 changes: 9 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,15 @@ def read(fname, encoding="ascii"):
],
},
extras_require={
"slack": [
"errbot-backend-slackv3==0.2.1",
],
"discord": [
"err-backend-discord==3.0.1",
],
"mattermost": [
"err-backend-mattermost==3.0.0",
],
"IRC": [
"irc==20.0.0",
],
Expand Down

0 comments on commit 6f664aa

Please sign in to comment.