Closed zufardhiyaulhaq closed 3 years ago
@J-Rios can you check & review? thanks
also, I want to ask something, why we don't directly use an environment variable for telegram bot token and bot language, hardcode in the code seems to make deployment hard since we need to upload the image in a private registry. If we use an environment variable, we can use a single image and deploy to multiple environments like docker, compose, or even kubernetes.
Please take a look into last commits. Docker build was revisited: some fixes, simplified and removed unnecessary Bot Token and language setup...
https://github.com/J-Rios/TLG_JoinCaptchaBot/commit/38257eed0a50ac918096eefdb428ceac96774e8e
So now, you can setup any environment variable like you specify, including Bot token with something like:
sudo docker run -d --name captcha-bot --env CAPTCHABOT_TOKEN="XXXXXXXXX:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" captcha-bot
Note that I don't have too much knowledge regarding Docker, and making deployments are not something that I commonly do, so I'm not really familiar to all of this, if you see something that can be modified for a better approach, feel free to comment it opening an issue or pull request :)
Best Regards.
python:3-slim-buster
image currently using python 3.9 that doesn't support byPillow 7.1.2
. https://pillow.readthedocs.io/en/stable/installation.htmlsettings.py
. Fix seeding directly to thesettings.py
Signed-off-by: zufardhiyaulhaq zufardhiyaulhaq@gmail.com