-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathDockerfile
45 lines (35 loc) · 1.13 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# Start with the NVIDIA CUDA base image
FROM nvidia/cuda:12.1.1-devel-ubuntu22.04
LABEL com.nvidia.volumes.needed="nvidia_driver"
# Update and install essential packages
RUN apt-get update && apt-get install -y \
ca-certificates \
build-essential \
python3 \
python3-pip \
git \
curl \
wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Set up the NVIDIA environment
ENV PATH=/usr/local/nvidia/bin:${PATH}
ENV LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64:${LD_LIBRARY_PATH}
# Clone and build Hashcat
RUN mkdir -p /hashcat && \
cd /hashcat && \
git clone https://github.com/hashcat/hashcat.git . && \
git submodule update --init && \
make install && \
rm -rf .git
# Set up the Python environment
RUN pip3 install --upgrade pip
# Create a subfolder for script output
RUN mkdir -p /app/data
# Set the working directory to the script output folder
WORKDIR /app/data
# Entrypoint script to dynamically pull the latest Python script and run it
COPY entry.sh /app/entry.sh
RUN chmod +x /app/entry.sh
# Set the entrypoint to the custom script
ENTRYPOINT ["/app/entry.sh"]