Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latest Alpine and XMR_Rig #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
# usage: docker run mkell43/xmrig-cpu -o miningpool.url:port -u username -p password

FROM alpine:3.7 as build
FROM alpine as build

ENV XMRIG_DIR /xmrig-cpu
ENV XMRIG_BUILD_DIR $XMRIG_DIR/build

RUN apk --no-cache add build-base cmake curl git libuv-dev
RUN apk --no-cache add build-base cmake curl git libuv-dev openssl-dev
RUN apk add --no-cache --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing hwloc-dev
# Use xmrig v2.4.2
RUN git clone https://github.com/xmrig/xmrig.git $XMRIG_DIR && cd $XMRIG_DIR && \
git reset --hard fd029201b00bab2948cbe0ed67ff162e10aa9dfe
RUN git clone https://github.com/xmrig/xmrig.git $XMRIG_DIR && cd $XMRIG_DIR
RUN mkdir $XMRIG_BUILD_DIR && cd $XMRIG_BUILD_DIR && \
cmake .. -DWITH_HTTPD=OFF && make
RUN mv $XMRIG_BUILD_DIR/xmrig /usr/bin/

FROM alpine:3.7
FROM alpine
RUN apk --no-cache add libuv-dev
RUN apk add --no-cache --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing hwloc-dev
COPY --from=build /usr/bin/xmrig /usr/bin/
ENTRYPOINT ["xmrig"]