/xmrig

An up-to-date and easy to use XMRig image for mining Monero on any Docker host including Azure ACI and AWS ECS.

Primary LanguageDockerfile

Docker Pulls

XMRig

This XMRig image is kept up to date with the latest updates and is custom built in an Alpine container for best performance and size.

This image will CPU mine very well on any Docker host including Azure and AWS.

If you are new to Monero mining and need a wallet/address see the official wallet client.

Getting Started

The most simple execution is:

docker run --restart=always miningcontainers/xmrig:latest -k --tls -o POOL:PORT -u USER -p PASSWORD 

An excellent Monero mining pool is SupportXMR. To mine at SupportXMR you use your monero wallet address as the username, and password is not required.

For Example:

docker run --restart=always miningcontainers/xmrig:latest -k --tls -o pool.supportxmr.com:443 -u 48edfHu7V9Z84YzzMa6fUueoELZ9ZRXq9VetWzYGzKt52XU5xvqgzYnDK9URnRoJMk1j8nLwEVsaSWJ4fhdUyZijBGUicoD 

Here is another example for Nanopool (nanopool difficulty may be too high for low resource machines):

docker run --restart=always miningcontainers/xmrig:latest --tls -o xmr-us-east1.nanopool.org:14433 -u 48edfHu7V9Z84YzzMa6fUueoELZ9ZRXq9VetWzYGzKt52XU5xvqgzYnDK9URnRoJMk1j8nLwEVsaSWJ4fhdUyZijBGUicoD --coin monero

Running in Azure ACI

You can deploy directly to Azure Container Instances using our ARM template with the following button. This will be a single container, so you may want to modify the template to duplicate the container instances a few times.

Deploy to Azure

Or you can run manually using the native support in Docker Desktop for Windows/Mac.

You simply log Docker into Azure, create a context, and include the context on your normal run command.

Example:

docker login azure
docker context create aci myacicontext
docker --context myacicontext run miningcontainers/xmrig:latest -k --tls -o POOL:PORT -u USER -p PASSWORD 

Learn more at https://docs.docker.com/cloud/aci-integration/.

Running in AWS ECS

Running in ECS is similar to running in ACI. You can follow the instructions at: https://docs.docker.com/cloud/ecs-integration/

Improve performance on Linux hosts

By disabling prefetching you can see up to 30% performance gain. Usually XMRIG would do this automatically but it is not possible from inside the docker image.

You can run this command on the Linux host to use the XMRIG script to configure MSR (until next reboot):

sudo wget https://raw.githubusercontent.com/xmrig/xmrig/dev/scripts/randomx_boost.sh -v -O randomx_boost.sh; ./randomx_boost.sh; rm -rf randomx_boost.sh