Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM python:3.10-alpine

RUN apk update \
&& apk add --no-cache --virtual .build-deps git g++ postgresql-dev yaml-dev \
&& apk add --no-cache libpq

WORKDIR /var/src/lnt

COPY requirements.server.txt setup.py .
# setup.py uses lnt.__version__ etc.
COPY lnt/__init__.py lnt/__init__.py
# we build the cperf extension during install
COPY lnt/testing/profile lnt/testing/profile

RUN pip3 install -r requirements.server.txt \
&& apk --purge del .build-deps \
&& mkdir /var/log/lnt

COPY . .
COPY docker/docker-entrypoint.sh docker/wait_db /usr/local/bin/

VOLUME /var/log

EXPOSE 8000

ENV DB_ENGINE= DB_HOST= DB_USER= DB_PWD= DB_BASE=

ENTRYPOINT docker-entrypoint.sh
6 changes: 3 additions & 3 deletions docker/docker-compose.yml → docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ services:

db:
container_name: lnt-postgres
image: postgres:11-alpine
image: docker.io/postgres:13-alpine
environment:
- POSTGRES_PASSWORD=${DB_PWD}
- POSTGRES_USER=${DB_USER}
- POSTGRES_DB=${DB_BASE}
- POSTGRES_USER=${DB_USER:-lntuser}
- POSTGRES_DB=${DB_BASE:-lnt}
2 changes: 0 additions & 2 deletions docker/.env

This file was deleted.

20 changes: 0 additions & 20 deletions docker/Dockerfile

This file was deleted.

4 changes: 2 additions & 2 deletions requirements.server.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
.
psycopg2==2.9.10
gunicorn==19.9.0
Jinja2==3.1.6
Jinja2==2.11.3
progressbar2
pyyaml==6.0
pyyaml==5.1.2
Loading