Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
7 changes: 7 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
venv
.venv
.env
.gitea
example.env
LICENSE
README.md
43 changes: 0 additions & 43 deletions .gitea/workflows/build.yaml

This file was deleted.

12 changes: 12 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: If it builds, it probably works

on:
push:
pull_request:
jobs:
build-telegram-bot:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build the sd_telegram Docker image
run: docker build . -t sd_telegram:$(date +%s)
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.vscode
.venv
.env
.env
venv
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ docker run -e VK_TOKEN='VK_TOKEN_HERE' \
-e SD_USERNAME='user' \
-e SD_PASSWORD='1234' \
-e DEBUG='no' \
-e ALLOWED_USERS='[id1, id2, id3]' # где id - id пользователей telegram в виде числа (пример: [1234, 5678]) без апострофов и тд, если хотите сделать бота общедоступным, то дайте значение '[]'
soaska.ru/soaska/sd_telegram:latest
```

Expand Down
193 changes: 109 additions & 84 deletions bot.py

Large diffs are not rendered by default.

8 changes: 5 additions & 3 deletions dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
FROM python:3.11
LABEL maintainer="[email protected]"
FROM python:3.10
LABEL maintainer="[email protected]"
LABEL org.opencontainers.image.source=https://github.com/soaska/sd_telegram
LABEL org.opencontainers.image.description="Beta image for sd_telegram"

WORKDIR /bot
COPY requirements.txt .
RUN pip install -r requirements.txt

COPY . .
CMD ["python", "bot.py"]
CMD ["python", "bot.py"]
5 changes: 4 additions & 1 deletion example.env
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,7 @@ SD_HOST = '127.0.0.1'
SD_PORT = '7861'
SD_USERNAME = 'user'
SD_PASSWORD = '1234'
DEBUG = 'no' # 'yes' to debug
DEBUG = 'no' # 'yes' to debug
# ids are type int
#ALLOWED_USERS = '[id1, id2, idN]'
ALLOWED_USERS = '[]' # for public access
2 changes: 2 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
aiogram==2.22.2
wheel
webuiapi
translate
# torch
transformers
vk_api
ok_api
Expand Down
Loading