kopia lustrzana https://github.com/mkdryden/telegram-stats-bot
Update docker and docker-compose
rodzic
91c60ad871
commit
69e905e1e2
|
@ -23,6 +23,8 @@ Changed
|
|||
- Separate SQL code from db_init function
|
||||
- Update to psycopg 3.0
|
||||
- Add more protection against bad stats options
|
||||
- Upgrade docker image to python 3.11
|
||||
- Update docker-compose file to use postgres 16
|
||||
|
||||
Fixed
|
||||
-----
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
FROM python:3.9
|
||||
FROM python:3.11
|
||||
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
COPY . .
|
||||
RUN pip install .
|
||||
|
||||
ENV TZ="America/Toronto" \
|
||||
ENV TZ="America/New_York" \
|
||||
BOT_TOKEN=-1 \
|
||||
CHAT_ID=0 \
|
||||
POSTGRES_USER=postgres \
|
||||
|
@ -13,4 +13,4 @@ ENV TZ="America/Toronto" \
|
|||
POSTGRES_HOST=db \
|
||||
POSTGRES_DB=telegram_bot
|
||||
|
||||
CMD [ "sh", "-c", "python -m telegram_stats_bot.main --tz=$TZ $BOT_TOKEN $CHAT_ID postgresql://$POSTGRES_USER:$POSTGRES_PASSWORD@$POSTGRES_HOST/$POSTGRES_DB" ]
|
||||
CMD [ "sh", "-c", "python -m telegram_stats_bot.main --tz=$TZ $BOT_TOKEN $CHAT_ID postgresql+psycopg://$POSTGRES_USER:$POSTGRES_PASSWORD@$POSTGRES_HOST/$POSTGRES_DB" ]
|
||||
|
|
|
@ -17,7 +17,7 @@ services:
|
|||
POSTGRES_HOST: db
|
||||
POSTGRES_DB: telegram_bot
|
||||
db:
|
||||
image: postgres:12
|
||||
image: postgres:16
|
||||
restart: always
|
||||
volumes:
|
||||
- db-data:/var/lib/postgresql/data
|
||||
|
|
Ładowanie…
Reference in New Issue