Convert into docker image

This commit is contained in:
Kaspar Laineste 2024-06-06 21:59:56 +03:00
parent 2c1bb13be8
commit 5c437ead89
2 changed files with 31 additions and 0 deletions

21
Dockerfile Normal file
View File

@ -0,0 +1,21 @@
FROM nvidia/cuda:12.0.1-devel-ubuntu20.04
WORKDIR /app
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get install -y ocl-icd-opencl-dev nano cmake python3-pip git
RUN git clone https://github.com/shanhaicoder/XENGPUMiner.git
WORKDIR /app/XENGPUMiner
RUN chmod +x build.sh && ./build.sh
RUN pip install -U -r requirements.txt
COPY entrypoint.sh /app/XENGPUMiner
RUN chmod +x entrypoint.sh
ENTRYPOINT ["/app/XENGPUMiner/entrypoint.sh"]

10
entrypoint.sh Normal file
View File

@ -0,0 +1,10 @@
#!/bin/bash
sed -i 's/account = 0x24691e54afafe2416a8252097c9ca67557271475/account = 0x1B9786D1B9e1e347Cf791b3aFf8518A837E8715f/g' config.conf
echo "STEP 8 of 10: Replaced ETH address"
echo "STEP 10 of 10: Starting Miner & GPU"
cat config.conf
pwd
ls
./miner.sh -g 1 -c 1