I'm setting up a django server application on docker. docker runs the container well but the command to run django is not taking by docker.
I've already gone through few youtube videos but none of them worked for me
Dockerfile
FROM python:3.6-stretch
MAINTAINER ***
ENV PYTHONBUFFERED 1
COPY ./requirements.txt /requirements.txt
RUN pip install -r /requirements.txt
RUN mkdir /specfolder
WORKDIR /specfolder
COPY ./myfolder /specfolder
EXPOSE 8000
CMD ["python", "manage.py runserver"]
i've tried placing the command under docker-compose.yml file under
commands: sh -c "python manager.py runserver"
but none of them worked
docker-compose.yml file
version: "3"
services:
myapp:
build:
context: .
ports:
- "8000:8000"
volumes:
- ./myfolder:/specfolder
requriements.txt
django==2.2.4
pandas
xlrd
xlsxwriter
as of now under kinematics i am getting the python shell
Type "help", "copyright", "credits" or "license" for more information.
>>> 2019-08-31T13:34:51.844192800Z Python 3.6.9 (default, Aug 14 2019,
13:02:21)
[GCC 6.3.0 20170516] on linux
unable to access the 127.0.0.1:8000/myapp/login in the browser.