This project provides a Docker container for downloading files from Telegram using the app.py Python script.
To build the Docker image, run the following command:
docker build --build-arg UID=$(id -u) --build-arg GID=$(id -g) -t telegram-downloader . --no-cacheTo run the Docker container, use the following command:
docker run -d \
--name telegram-downloader \
--env-file .env \
--mount type=bind,source="$(pwd)/downloader_session.session",target=/app/downloader_session.session \
--mount type=bind,source="${DOWNLOAD_BASE_PATH}",target="${DOWNLOAD_BASE_PATH}" \
--restart unless-stopped \
telegram-downloaderdocker start: Starts the container.docker save telegram-downloader:latest: Saves the image to a file.docker ps -a: Lists all containers.docker rm: Removes a container.docker rmi: Removes an image.docker stats: Displays container statistics.
This script is used as the entrypoint for the Docker container. It starts the app.py Python script when the container is run.
This script is used to run the app.py Python script on Windows.
To use this project, follow these steps:
- Build the Docker image using the
docker buildcommand. - Run the Docker container using the
docker runcommand. - Use the
docker startanddocker stopcommands to control the container.
Note: This is a basic readme file, and you may need to add more information depending on your specific use case.