update README.md with docker run command. Update Dockerfile (ADD ./TwitchChannelPointsMiner)

This commit is contained in:
Alessandro Maggio
2021-11-18 15:14:33 +01:00
parent e1ee6ea245
commit f81c96085d
3 changed files with 20 additions and 8 deletions

View File

@@ -28,7 +28,7 @@ jobs:
context: .
push: true
tags: |
tkdalex/twitch-channel-points-miner-v2:latest
tkdalex/twitch-channel-points-miner-v2:latest
platforms: linux/amd64,linux/arm64,linux/arm/v7
build-args: BUILDX_QEMU_ENV=true
- name: Image digest

View File

@@ -4,7 +4,8 @@ ARG BUILDX_QEMU_ENV
WORKDIR /usr/src/app
COPY ./miner/requirements.txt ./
COPY ./requirements.txt ./
RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --fix-missing --no-install-recommends \
gcc \
@@ -25,5 +26,5 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get install -qq -y --fix-missing --no-ins
&& rm -rf /var/lib/apt/lists/* \
&& rm -rf /usr/share/doc/*
COPY ./miner .
CMD [ "python", "./main.py" ]
ADD ./TwitchChannelPointsMiner ./TwitchChannelPointsMiner
ENTRYPOINT [ "python", "run.py" ]

View File

@@ -293,7 +293,7 @@ Install the package via pip, you will find a stable version - maybe a different
The following file is mounted :
- main.py : this is your starter script with your configuration
- run.py : this is your starter script with your configuration
These folders are mounted :
@@ -301,14 +301,14 @@ These folders are mounted :
- cookies : to provide login information
- logs : to keep logs outside of container
Example using docker-compose:
**Example using docker-compose:**
```yml
version: "3.9"
services:
miner:
image: mrcraftcod/twitch-miner
image: tkdalex/twitch-channel-points-miner-v2
tty: true
environment:
- TERM=xterm-256color
@@ -316,11 +316,22 @@ services:
- ./analytics:/usr/src/app/analytics
- ./cookies:/usr/src/app/cookies
- ./logs:/usr/src/app/logs
- ./main.py:/usr/src/app/main.py:ro
- ./run.py:/usr/src/app/run.py:ro
ports:
- "5000:5000"
```
Example with docker run:
```sh
docker run \
-v $(pwd)/analytics:/usr/src/app/analytics \
-v $(pwd)/cookies:/usr/src/app/cookies \
-v $(pwd)/logs:/usr/src/app/logs \
-v $(pwd)/run.py:/usr/src/app/run.py:ro \
-p 5000:5000 \
tkdalex/twitch-channel-points-miner-v2
```
### Limits
> Twitch has a limit - you can't watch more than two channels at one time. We take the first two streamers from the list as they have the highest priority.