Skip to content

Commit

Permalink
Change to debian because apline not building
Browse files Browse the repository at this point in the history
  • Loading branch information
zemogle committed Jul 4, 2022
1 parent 9331c1f commit 95ff694
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 28 deletions.
43 changes: 17 additions & 26 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,30 +1,21 @@
FROM python:3.8-alpine
FROM python:3.9-slim-buster
WORKDIR /app

# install depedencies
COPY requirements.pip /app/requirements.pip
RUN apk --no-cache add \
libgomp \
libjpeg-turbo \
postgresql-libs \
openblas \
zlib \
freetype-dev \
libxslt-dev \
&& apk --no-cache add --virtual .build-deps \
g++ \
gcc \
git \
libjpeg-turbo-dev \
postgresql-dev \
musl-dev \
openblas-dev \
zlib-dev \
libffi-dev \
file \
make \
&& pip --no-cache-dir --trusted-host=buildsba.lco.gtn install -r requirements.pip \
&& apk --no-cache del .build-deps
COPY requirements.txt /app/requirements.txt

RUN buildDeps='gcc g++' && \
apt-get update && \
apt-get install $buildDeps --no-install-recommends -y \
gettext python3-cffi libcairo2 libpango-1.0-0 \
libjpeg62-turbo-dev zlib1g-dev \
postgresql-11 libpq-dev \
libpangocairo-1.0-0 libgdk-pixbuf2.0-0 libffi-dev shared-mime-info -y \
&& python3 -m pip install -r requirements.txt \
&& apt-get purge $buildDeps -y \
&& apt-get purge $(aptitude search '~i!~M!~prequired!~pimportant!~R~prequired!~R~R~prequired!~R~pimportant!~R~R~pimportant!busybox!grub!initramfs-tools' | awk '{print $2}') -y \
&& apt-get purge aptitude -y \
&& apt-get autoremove -y \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

# install web application
COPY . /app
4 changes: 2 additions & 2 deletions requirements.pip → requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ gunicorn[gevent]==20.1.0
gevent==21.12.0
profanityfilter==2.0.6
django-cors-headers==3.11.0
numpy==1.22.3
astropy==4.0
numpy==1.18
astropy==5.1
astroplan==0.8
astroscrappy==1.1.0
fits2image>=0.4.0
Expand Down

0 comments on commit 95ff694

Please sign in to comment.