This commit is contained in:
tobwiens 2018-03-18 17:30:55 +00:00 committed by GitHub
commit 60cca6336e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

26
Dockerfile Normal file
View file

@ -0,0 +1,26 @@
#
# Dockerfile for xmrig
# usage: docker build -t xmrig:latest.
# run: docker run --name xmrig --restart unless-stopped -d xmrig:latest [XMRIG EXECUTABLE ARGUMENTS]
#
FROM ubuntu:16.04
ENV HOME_DIR /root
ENV XMRIG_DIR $HOME_DIR/xmrig
ENV XMRIG_BUILD_DIR $XMRIG_DIR/build
RUN apt-get update && apt-get install -y software-properties-common
RUN add-apt-repository ppa:jonathonf/gcc-7.1 -y
RUN apt-get update && apt-get install git build-essential cmake libuv1-dev libmicrohttpd-dev gcc-7 g++-7 -y
WORKDIR $HOME_DIR
RUN git clone https://github.com/xmrig/xmrig.git
RUN mkdir $XMRIG_BUILD_DIR
RUN cd $XMRIG_BUILD_DIR && cmake $XMRIG_DIR -DCMAKE_C_COMPILER=gcc-7 -DCMAKE_CXX_COMPILER=g++-7
RUN cd $XMRIG_BUILD_DIR && make
ENTRYPOINT ["/root/xmrig/build/xmrig"]