add bash to alpine image
This commit is contained in:
12
Dockerfile
12
Dockerfile
@@ -1,4 +1,4 @@
|
|||||||
FROM alpine:latest
|
FROM python:alpine3.20
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
@@ -9,16 +9,14 @@ RUN chmod 0644 /etc/cron.d/django_crons_jobs && crontab /etc/cron.d/django_crons
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
RUN apk update && apk add --no-cache mariadb-connector-c-dev && apk add --no-cache mariadb-connector-c-dev gcc g++ libxslt-dev musl-dev nodejs npm git docker libffi-dev libffi curl libxml2-dev libxslt-dev py3-lxml mariadb python3-dev
|
RUN apk update && apk add --no-cache mariadb-connector-c-dev && apk add --no-cache mariadb-connector-c-dev gcc g++ libxslt-dev musl-dev nodejs npm git docker libffi-dev libffi curl libxml2-dev libxslt-dev py3-lxml mariadb python3-dev bash
|
||||||
RUN python -m venv venv \
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
&& . venv/bin/activate \
|
|
||||||
&& pip install --no-cache-dir -r requirements.txt
|
|
||||||
RUN source venv/bin/activate && python manage.py makemigrations && python manage.py migrate
|
RUN source venv/bin/activate && python manage.py makemigrations && python manage.py migrate
|
||||||
|
|
||||||
|
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
|
|
||||||
#CMD ["python", "manage.py", "runserver", "0.0.0.0:8080"]
|
CMD ["python", "manage.py", "runserver", "0.0.0.0:8080"]
|
||||||
CMD ["bash", "-c", "source venv/bin/activate && python manage.py runserver 0.0.0.0:8080"]
|
#CMD ["bash", "-c", "source venv/bin/activate && python manage.py runserver 0.0.0.0:8080"]
|
||||||
#CMD ["./startup.sh"]
|
#CMD ["./startup.sh"]
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user