Connect with us

ViralNewsDude.com

How can I assign almost definitely the most attention-grabbing configurations for the project working with django, docker and mysql?


Viral News

How can I assign almost definitely the most attention-grabbing configurations for the project working with django, docker and mysql?

I was reading an article in here which is about setting up project using docker, django and mysql together. these are my files in project: Dockerfile FROM python:3.7 MAINTAINER masoud masoumi moghadam ENV PYTHONUNBUFFERED 1 RUN mkdir /app WORKDIR /app ADD . /app ADD requirements.txt /app/requirements.txt RUN pip install –upgrade pip && pip install -r…

How can I assign almost definitely the most attention-grabbing configurations for the project working with django, docker and mysql?

I became reading an article in right here which is about developing project utilizing docker, django and mysql together.

these are my files in project:

Dockerfile

FROM python:3.7
MAINTAINER masoud masoumi moghadam
ENV PYTHONUNBUFFERED 1

RUN mkdir /app
WORKDIR /app
ADD . /app

ADD requirements.txt /app/requirements.txt

RUN pip install --purple meat up pip && pip install -r requirements.txt

Docker-gain

version: "3"

companies:
  app:
    originate:
      context: .
    ports:
      - "8000: 8000"
    volumes:
      - ./app:/app
    expose: >
      sh -c "python manage.py runserver 0.0.0.0: 8000"
    ambiance:
      - DB_HOST=localhost
      - DB_NAME=contact_list
      - DB_USER=root
      - DB_PASS=secretpassword
    depends_on:
      - db

  db:
    image: mysql:5.7
    ambiance:
      - MYSQL_DATABASE=contact_list
      - MYSQL_USER=root
      - MYSQL_PASSWORD=secretpassword

requirements

Django>=2.0,<3.0
djangorestframework<3.10.0
mysqlclient==1.3.13
django-mysql==2.2.0

and furthermore this

Subscribe to the newsletter news

We hate SPAM and promise to keep your email address safe

Click to comment

Leave a Reply

Your email address will not be published. Required fields are marked *

What’s Hot

To Top