build: add and update docker with compose

This commit is contained in:
spifory 2026-02-12 17:42:58 +02:00
parent 7f5a534822
commit 2b924b5d25
No known key found for this signature in database
GPG Key ID: A09D250DB53F8BD7
3 changed files with 24 additions and 2 deletions

5
.dockerignore Normal file
View File

@ -0,0 +1,5 @@
*
!src*
!poetry*
!pyproject.toml
!.env

View File

@ -1,9 +1,13 @@
FROM python:3.11-bookworm FROM python:3.14-slim-trixie
WORKDIR /sox
RUN pip install poetry RUN pip install poetry
COPY . . COPY pyproject.toml poetry.lock ./
RUN poetry install --without=dev RUN poetry install --without=dev
COPY . .
CMD ["poetry", "run", "python", "-m", "src"] CMD ["poetry", "run", "python", "-m", "src"]

13
docker-compose.yaml Normal file
View File

@ -0,0 +1,13 @@
services:
sox:
container_name: sox
pull_policy: build
build:
context: .
dockerfile: Dockerfile
environment:
TOKEN: ${TOKEN?Bot token not provided}
FUN_GUILD: ${FUN_GUILD?Main guild ID not provided}
WELCOME_CHANNEL: $WELCOME_CHANNEL
MEMBER_ROLE: $MEMBER_ROLE