Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
Added fix for DockerFile as pointed out by attiladoor
  • Loading branch information
WyvernTKC authored May 16, 2021
1 parent 10a7862 commit 37307ef
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#
# Dockerfile for cpuminer-opt
# usage: docker build -t cpuminer-opt:latest .
# run: docker run -it --rm cpuminer-opt:latest [ARGS]
# ex: docker run -it --rm cpuminer-opt:latest -a cryptonight -o cryptonight.eu.nicehash.com:3355 -u 1MiningDW2GKzf4VQfmp4q2XoUvR6iy6PD.worker1 -p x -t 3
#

# for enabling huge pages, add --privileged flag
# for enabling MSR add additonal --cap-add=ALL -v /lib/modules:/lib/modules flags (only on linux host)
# Contributed by attiladoor
# Build
FROM ubuntu:16.04 as builder
FROM ubuntu:20.04 as builder

RUN apt-get update \
&& apt-get install -y \
Expand All @@ -16,18 +16,21 @@ RUN apt-get update \
libcurl4-openssl-dev \
libjansson-dev \
automake \
zlib1g-dev \
&& rm -rf /var/lib/apt/lists/*

COPY . /app/
RUN cd /app/ && ./build.sh

# App
FROM ubuntu:16.04
#App
FROM ubuntu:20.04

RUN apt-get update \
&& apt-get install -y \
libcurl3 \
libcurl4 \
libjansson4 \
kmod \
msr-tools \
&& rm -rf /var/lib/apt/lists/*

COPY --from=builder /app/cpuminer .
Expand Down

0 comments on commit 37307ef

Please sign in to comment.