Added Assets

This commit is contained in:
Christian Risi 2025-05-15 11:37:01 +02:00
parent 7dd3f083b3
commit adedc2277a
7 changed files with 61 additions and 0 deletions

0
assets/.gitkeep Normal file
View File

View File

View File

View File

@ -0,0 +1,7 @@
FROM fedora:41
RUN dnf install -y socat
WORKDIR /service/
ADD ./okay /service/okay
RUN chmod +x ./okay
ENTRYPOINT ["socat", "-d", "TCP-LISTEN:3000,reuseaddr,fork", "EXEC:timeout -k 5 30 ./okay"]

View File

@ -0,0 +1,9 @@
FROM python:3.6-slim
RUN apt-get update && apt-get install -y socat gcc g++ make libffi-dev libssl-dev
WORKDIR /service/
COPY ./requirements.txt ./requirements.txt
RUN pip install -r requirements.txt
ADD ./main.py ./main.py
RUN chmod +x main.py
ENTRYPOINT socat -d TCP-LISTEN:3000,reuseaddr,fork EXEC:'timeout -k 5 30 python3 -u main.py'

View File

@ -0,0 +1,20 @@
FROM docker.io/oven/bun AS frontend
WORKDIR /app
COPY frontend/package*.json ./
RUN bun i
COPY frontend/ .
RUN bun run build
FROM python:3.12-slim
ENV DOCKER=1
WORKDIR /app
COPY ./backend/requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY ./backend/ .
COPY --from=frontend /app/dist /app/frontend
CMD ["python3", "app.py"]

View File

@ -0,0 +1,25 @@
FROM docker.io/oven/bun AS frontend
WORKDIR /app
COPY frontend/package*.json ./
RUN bun i
COPY frontend/ .
RUN bun run build
FROM python:3.12-slim
ENV DOCKER=1
WORKDIR /app
COPY ./backend/requirements.txt \
.
RUN pip install --no-cache-dir -r \
requirements.txt
COPY ./backend/ \
\
\
.
COPY --from=frontend /app/dist /app/frontend
CMD ["python3", "app.py"]