It looks like you may be missing a space after the word "source".
My fabfile has these helpers, given an env.virtualenv and env.app_dir setting... def ve_run(command, func=run, base_dir=None, *args, **kwargs): base_dir = base_dir or env.app_dir with cd(base_dir): with prefix("source /opt/virtualenvs/%s/bin/activate" % env.virtualenv): return func(command, *args, **kwargs) def manage(*args): return ve_run("python manage.py " + ' '.join(args)) I've had problems with custom settings (with Django 1.3 FWIW) which meant I had to use django-admin.py, so if the above doesn't work, this might: def manage(*args): return _ve_run("django-admin.py " + ' '.join(args) + " --pythonpath . --settings %s%s" % (env.settings,)) Hope that helps, - Roger On Monday, 1 July 2013 16:28:21 UTC+10, Eduardo Basílio wrote: > > I use Python Fabric to deploy. Works great for accessing the remote > server, install dependencies, run linux commands, etc.. > > But when I try to run *file commands manage.py Django*, NOT work! > > > Example of my fabfile.py: > > with prefix ('source/home/user/env/bin/activate'): > > with cd ('path/to/your/project/django'): > > *run ('python manage.py help --settings=path.for.settings')* > > > Fatal error: runstrong text() received nonzero return code while executing > one! > > > I've tried putting a --noinput but the error remains: > > *run ('python manage.py help --settings=caminho.para.settings --noinput')* > > Does anyone know how to solve? > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at http://groups.google.com/group/django-users. For more options, visit https://groups.google.com/groups/opt_out.