Skip to content

Commit

Permalink
Merge 544fdf1 into 46ad18f
Browse files Browse the repository at this point in the history
  • Loading branch information
YulianSalo committed Oct 21, 2020
2 parents 46ad18f + 544fdf1 commit b9a2628
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
29 changes: 29 additions & 0 deletions Dockerfile
@@ -0,0 +1,29 @@
#adding Django dependencies
FROM django

#adding Python 3.7 dependencies
FROM python:3.7

#creating working directory
ADD . /django-cms

#switching to woring directory
WORKDIR /django-cms

#RUN pip3 install --upgrade virtualenv

# RUN virtualenv env

# RUN source env/bin/activate

#installing djangocms-installer
RUN pip3 install djangocms-installer

#creating and switching to working directory
WORKDIR /django-cms/my-project

#running djangocms
RUN djangocms -f -p . my_project

#opening tpc/8000 port
EXPOSE 8000
24 changes: 24 additions & 0 deletions docker-compose.yml
@@ -0,0 +1,24 @@
version: '3.3'

services:
#postgresdb for djangoc-cms
db:
image: postgres
environment:
- POSTGRES_DB=djangodb
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres

#django-cms
django-cms:
build: .
command: python3 manage.py runserver 0.0.0.0:8000
container_name: django_cms
# environment:
# - DATABASE_URL
# volumes:
# - .:/code
ports:
- "8000:8000"
depends_on:
- db

0 comments on commit b9a2628

Please sign in to comment.