Skip to content

Commit 0609f26

Browse files
committed
fix jira requirement for alpine, cleanup Dockerfile
1 parent 882d067 commit 0609f26

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

Dockerfile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@ ENV ELASTALERT_HOME /opt/elastalert
99

1010
WORKDIR /opt
1111

12-
RUN apk update && apk upgrade && \
13-
apk add ca-certificates openssl-dev openssl python2-dev python2 py2-pip py2-yaml libffi-dev gcc musl-dev wget && \
12+
RUN apk add --update --no-cache ca-certificates openssl-dev openssl python2-dev python2 py2-pip py2-yaml libffi-dev gcc musl-dev wget && \
1413
# Download and unpack Elastalert.
1514
wget -O elastalert.zip "${ELASTALERT_URL}" && \
1615
unzip elastalert.zip && \
@@ -20,7 +19,9 @@ RUN apk update && apk upgrade && \
2019
WORKDIR "${ELASTALERT_HOME}"
2120

2221
# Install Elastalert.
23-
RUN python setup.py install && \
22+
# see: https://github.com/Yelp/elastalert/issues/1654
23+
RUN sed -i 's/jira>=1.0.10/jira>=1.0.10,<1.0.15/g' setup.py && \
24+
python setup.py install && \
2425
pip install -r requirements.txt
2526

2627
FROM node:alpine
@@ -30,7 +31,7 @@ ENV SET_CONTAINER_TIMEZONE False
3031
# Default container timezone as found under the directory /usr/share/zoneinfo/.
3132
ENV CONTAINER_TIMEZONE Etc/UTC
3233

33-
RUN apk update && apk upgrade && apk add --no-cache curl tzdata python2
34+
RUN apk add --update --no-cache curl tzdata python2 make
3435

3536
COPY --from=py-ea /usr/lib/python2.7/site-packages /usr/lib/python2.7/site-packages
3637
COPY --from=py-ea /opt/elastalert /opt/elastalert

0 commit comments

Comments
 (0)