FROM python:3.9

LABEL maintainer="Kirk Trombley <ktrom3894@gmail.com>"

WORKDIR /app/

RUN mkdir ./data/

ENV DATABASE_FILE="/app/data/rollbot.db"

ENV SECRET_FILE="/app/data/secrets.toml"

EXPOSE 5000

COPY logging.conf .

COPY ./rollbot/ /app/rollbot

RUN pip3 install -e /app/rollbot

COPY ./commands/ /app/commands

RUN pip3 install -e /app/commands

COPY ./drivers/groupme_driver.py .

RUN pip3 install uvicorn fastapi toml

CMD uvicorn groupme_driver:app --host 0.0.0.0 --port 5000 --root-path /rollbot
