Skip to content

Commit 7d9069c

Browse files
vbabiyauvipy
authored andcommitted
Fix postgres docker-compose setup, and expose rabbit for easier test running.
1 parent 3ac0525 commit 7d9069c

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

docker-compose.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@ services:
4343
- './django_celery_beat/:/app/django_celery_beat/'
4444

4545
rabbit:
46-
image: rabbitmq
47-
46+
image: rabbitmq
47+
ports:
48+
- "5672:5672"
4849
postgres:
4950
image: postgres
51+
environment:
52+
POSTGRES_PASSWORD: s3cr3t

docker/base/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ RUN django-admin startproject mysite
2929

3030
WORKDIR /mysite/
3131

32-
RUN echo 'DATABASES = {"default": {"ENGINE": "django.db.backends.postgresql", "NAME": "postgres", "USER": "postgres", "HOST": "postgres", "PORT": 5432}}' >> mysite/settings.py
32+
RUN echo 'DATABASES = {"default": {"ENGINE": "django.db.backends.postgresql", "NAME": "postgres", "USER": "postgres","PASSWORD": "s3cr3t", "HOST": "postgres", "PORT": 5432}}' >> mysite/settings.py
3333
RUN echo 'ALLOWED_HOSTS = ["*"]' >> mysite/settings.py
3434
RUN echo 'INSTALLED_APPS += ("django_celery_beat", )' >> mysite/settings.py
3535
RUN echo 'INSTALLED_APPS += ("django_createsuperuserwithpassword", )' >> mysite/settings.py

0 commit comments

Comments
 (0)