1

I am deploying an existing Django project (with multiple apps) to Heroku. I have followed the steps in the Heroku docs. When I run heroku run python manage.py syncdb I get the following error:

Running `python manage.py syncdb` attached to terminal... failed
 !    No app specified.
 !    Run this command from an app folder or specify which app to use with --app APP.

I tried these suggestions, but the problem persists. Also, I wonder if there's a way to automatically create the database tables for all my existing apps without having to specify each one.

I am also using South, and I am still not sure how to properly transfer my migrations to Heroku. Perhaps that is part of the problem?

2
  • Are you in the main directory of your project? Are you able to run "git push heroku master" successfully? Commented Oct 4, 2012 at 22:25
  • I am. However, I have been working on a secondary branch (so I don't screw things up too significantly). I have been pushing using git push heroku secondary_brach_name:master. Could that be the problem? Commented Oct 4, 2012 at 22:30

1 Answer 1

2
git remote add heroku [email protected]:{YOUR_APP_NAME}.git
git config heroku.remote heroku

The app being referred to here is not your django app, but your project name.

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

3 Comments

I don't think that's the problem. That remote already exists for me.
Do you have more than 1 git remote?
Thanks for your help. I solved the problem, though I'm a bit confused as to why it worked. Instead of running the commands from my project directory (where my manage.py resides), I had to go up one directory and do heroku run python my_django_project_name/manage.py syncdb

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.