This commit is contained in:
2026-09-05 00:37:05 +05:00
commit e48b026e3f
3 changed files with 46 additions and 0 deletions
+20
View File
@@ -0,0 +1,20 @@
FROM debian:stable-slim AS build
RUN apt update \
&& apt upgrade -y \
&& apt install -y make git zlib1g-dev libssl-dev gperf cmake clang libc++-dev libc++abi-dev
WORKDIR /root
RUN git clone --recursive https://github.com/tdlib/telegram-bot-api.git \
&& rm -rf telegram-bot-api/build \
&& mkdir telegram-bot-api/build
WORKDIR /root/telegram-bot-api/build
RUN CXXFLAGS="-stdlib=libc++" CC=/usr/bin/clang CXX=/usr/bin/clang++ cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=/usr/local .. \
&& cmake --build . --target install
FROM debian:stable-slim
COPY --from=build /usr/local/bin/telegram-bot-api /usr/local/bin/telegram-bot-api
CMD /usr/local/bin/telegram-bot-api
+21
View File
@@ -0,0 +1,21 @@
## Telegram Bot API
### build
```bash
docker compose build
```
### Run on server
```bash
services:
tgbotapi:
hostname: tgbotapi
image: git.shihaam.dev/dockerfiles/tgbotapi
ports:
- 8080:8080
environment:
- TELEGRAM_API_ID=
- TELEGRAM_API_HASH=
```
+5
View File
@@ -0,0 +1,5 @@
services:
tgbotapi:
build: .
hostname: tgbotapi
image: git.shihaam.dev/dockerfiles/tgbotapi