1

I'm using the same docker-compose file to run an environment with django and postgresql.

When I run the environment on my local virtual machine (using docker-machine virtualbox driver and boot2docker distribution) and run migrations or tests it all works.

Deploying the exact same environment to digitalOcean running ubutu 14.04 I can't run migrations or tests.

Both environments run Django 1.8 and postgres 9.4.5.

The portal container runs on the ubuntu dist runs python 2.7.11 and the portal container on the boot2docker runs python 2.7.10

I can connect to the DB from django manually but for some reason trying to run the migrations or tests just stops after some time period.

The postgres sql logs not showing any error and the python process also not throwing any exceptions.

Every time I try to run the migrations, The process stops on the next line:

Creating test database for alias 'default'...

And then just exists.

I'm not sure what am I missing.

my docker-compose file:

portal:
  build: ./portal/
  ports:
    - "80"
  container_name: portal
  env_file: ./portal/.env
  links:
    - postgres:postgres
  command: waitress-serve --port=80  --threads=10 ltgss.wsgi:application


postgres:
 restart: always
 image: postgres:latest
 environment:
   POSTGRES_PASSWORD: 12345
   POSTGRES_USER: test
 container_name: postgres
 ports:
   - "5432:5432"

Thanks.

3
  • 1
    How much memory did you assign to your VM? Commented Dec 27, 2015 at 10:09
  • @RodrigoDela you were right, it was a memory problem. You can post an answer and I'll accept it. Thanks. Commented Dec 27, 2015 at 13:07
  • Sure, you're welcome! Commented Dec 27, 2015 at 13:27

1 Answer 1

1

Try to increase your VM's memory. I had a similar issue. After increasing my VM's memory everything worked fine.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.