|
|
|
FROM kalilinux/kali-rolling |
|
|
|
|
|
ENV PYTHONDONTWRITEBYTECODE 1 |
|
ENV PYTHONUNBUFFERED 1 |
|
ENV DEBIAN_FRONTEND=noninteractive |
|
ENV TERM=xterm-256color |
|
|
|
|
|
WORKDIR /app |
|
|
|
|
|
COPY ./ /app/ |
|
|
|
|
|
RUN apt-get update && \ |
|
apt-get install -y \ |
|
python3 \ |
|
python3-pip \ |
|
curl \ |
|
wget \ |
|
gnupg2 \ |
|
lsb-release \ |
|
nano \ |
|
apktool \ |
|
sudo \ |
|
netcat-traditional \ |
|
virtualbox \ |
|
virtualbox-dkms \ |
|
linux-headers-amd64 \ |
|
&& apt-get clean |
|
|
|
|
|
COPY requirements.txt /app/requirements.txt |
|
RUN pip install --no-cache-dir -r /app/requirements.txt |
|
|
|
|
|
RUN useradd -r -u 1000 -m -s /bin/bash appuser && \ |
|
chown -R appuser:appuser /app |
|
|
|
|
|
RUN chmod +x /app/* |
|
|
|
|
|
RUN echo "appuser ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/appuser && \ |
|
chmod 0440 /etc/sudoers.d/appuser |
|
|
|
|
|
USER appuser |
|
|
|
|
|
CMD ["python3", "-m", "pyxtermjs", "--host", "0.0.0.0", "-p", "7860"] |
|
|