17 lines
298 B
Docker
17 lines
298 B
Docker
|
# Use an official Python runtime as instance_a parent image
|
||
|
FROM python:3.9
|
||
|
|
||
|
# Set environment variables
|
||
|
ENV PYTHONDONTWRITEBYTECODE 1
|
||
|
ENV PYTHONUNBUFFERED 1
|
||
|
|
||
|
# Set work directory
|
||
|
WORKDIR /dns
|
||
|
|
||
|
COPY dns_server.py /dns/
|
||
|
|
||
|
RUN pip install dnslib
|
||
|
|
||
|
# Run the application
|
||
|
CMD ["python", "dns_server.py"]
|