mirror of
https://github.com/revanced/revanced-api.git
synced 2025-04-29 22:24:31 +02:00
Revert "build: slim down the docker container (#60)"
This reverts commit 80b858c5785468003c4df010ba206be2407c616e.
This commit is contained in:
parent
48500d58db
commit
e189c8264f
@ -1,6 +0,0 @@
|
||||
.idea
|
||||
.devcontainer
|
||||
.git
|
||||
.gitignore
|
||||
.github
|
||||
.vscode
|
2
.gitignore
vendored
2
.gitignore
vendored
@ -157,7 +157,7 @@ cython_debug/
|
||||
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
||||
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
||||
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
||||
.idea/
|
||||
#.idea/
|
||||
|
||||
# custom
|
||||
env.sh
|
||||
|
32
Dockerfile
32
Dockerfile
@ -1,36 +1,12 @@
|
||||
## Build dependencies
|
||||
FROM python:3.11-slim as dependencies
|
||||
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
RUN apt-get update && \
|
||||
apt-get install -y --no-install-recommends gcc git \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN python -m venv /opt/venv
|
||||
ENV PATH="/opt/venv/bin:$PATH"
|
||||
|
||||
COPY requirements.txt .
|
||||
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
## Image
|
||||
FROM python:3.11-slim
|
||||
|
||||
ARG GITHUB_TOKEN
|
||||
ENV GITHUB_TOKEN $GITHUB_TOKEN
|
||||
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
RUN apt-get update && \
|
||||
apt-get install -y --no-install-recommends curl \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ENV PATH="/opt/venv/bin:$PATH"
|
||||
|
||||
COPY --from=dependencies /opt/venv /opt/venv
|
||||
COPY . .
|
||||
|
||||
VOLUME persistance
|
||||
|
||||
CMD docker/run-backend.sh
|
||||
HEALTHCHECK CMD docker/run-healthcheck.sh
|
||||
|
||||
EXPOSE 8000
|
||||
CMD [ "python3", "-m" , "sanic", "app:app", "--fast", "--access-logs", "--motd", "--noisy-exceptions", "-H", "0.0.0.0"]
|
||||
|
@ -1 +0,0 @@
|
||||
python3 -m sanic /usr/src/app --fast --access-logs --motd --noisy-exceptions -H 0.0.0.0
|
@ -1 +0,0 @@
|
||||
curl --fail http://0.0.0.0:8000/docs
|
Loading…
x
Reference in New Issue
Block a user