diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..de9e012 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,12 @@ +local.env +*.log +.git/ +.idea/ +str.py +Procfile +README.md +downloads/ +raw_files/ +.gitignore +runtime.txt +__pycache__/ diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a276288 --- /dev/null +++ b/.gitignore @@ -0,0 +1,8 @@ +local.env +*.log +venv/ +.idea/ +*.session +raw_files/ +downloads/ +__pycache__/ diff --git a/.qovery.yml b/.qovery.yml new file mode 100644 index 0000000..97b6795 --- /dev/null +++ b/.qovery.yml @@ -0,0 +1,15 @@ +--- +application: + name: "groupmusicbot" + project: "ub" + organization: "QoveryCommunity" +databases: +- type: "MONGODB" + name: "ezila" + version: "4.4" +routers: +- name: "main-groupmusicbot" + routes: + - application_name: "groupmusicbot" + paths: + - "/*" diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..ae99dc5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM debian:latest +RUN apt update && apt upgrade -y +RUN apt install git curl python3-pip ffmpeg -y +RUN pip3 install -U pip +COPY . /app +WORKDIR /app +RUN pip3 install -U -r requirements.txt +CMD python3 -m StreamMusic diff --git a/Procfile b/Procfile new file mode 100644 index 0000000..e4dd31b --- /dev/null +++ b/Procfile @@ -0,0 +1 @@ +worker: python3 -m StreamMusic diff --git a/example.env b/example.env new file mode 100644 index 0000000..f464eb4 --- /dev/null +++ b/example.env @@ -0,0 +1,11 @@ +SESSION_NAME=session # If you don't deploy with docker, keep it as is and if you do so it should be a session string generated by "python str.py" +BOT_TOKEN=123456:abcdefghijklmnopqrstuv +BOT_NAME=HELLBOT +API_ID=123456 +API_HASH=abcdefghijklmnopqrstuv +SUDO_USERS=1111 2222 # List of user IDs separated by space +DURATION_LIMIT=10 # in minutes (default: 7) +ARQ_API_KEY= +UPDATES_CHANNEL= +BG_IMAGE= + diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..edf5183 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,18 @@ +Pyrogram +TgCrypto +pytgcalls +python-dotenv +youtube_dl +youtube_search_python +requests +aiohttp +aiofiles +asyncio +youtube_search +search_engine_parser +ffmpeg +Pillow +python-arq +future +psutil +wget diff --git a/runtime.txt b/runtime.txt new file mode 100644 index 0000000..e19f0bb --- /dev/null +++ b/runtime.txt @@ -0,0 +1 @@ +python-3.9.5 diff --git a/str.py b/str.py new file mode 100644 index 0000000..2029190 --- /dev/null +++ b/str.py @@ -0,0 +1,17 @@ +import asyncio + +from pyrogram import Client + +print("Enter your app information from my.telegram.org/apps below.") + + +async def main(): + async with Client( + ":memory:", api_id=int(input("API ID:")), api_hash=input("API HASH:") + ) as app: + print(await app.export_session_string()) + + +if __name__ == "__main__": + loop = asyncio.get_event_loop() + loop.run_until_complete(main())