deployment error : django + pgsql

41 views
Skip to first unread message

Govind Kumar Yadav

unread,
Dec 29, 2020, 9:44:58 AM12/29/20
to django...@googlegroups.com
hi I have been trying to deploy my Django project with pgsql on Linux with over nginx server but i am not able to migrate for my already existing project which works fine in my windows machine.
Help me to get over the issues.
regards ,
Govind 

Kasper Laudrup

unread,
Dec 29, 2020, 11:36:29 AM12/29/20
to django...@googlegroups.com
Hi Govind,
No one is able to help you get over your issues, since no one knows
which issues you are having apart from lack of communication skills.

Try to take the time to write a proper question and then I'm sure
someone will be happy to take the time and write a proper answer.

Kind regards,

Kasper Laudrup

Chetan Ganji

unread,
Dec 29, 2020, 11:41:18 AM12/29/20
to django...@googlegroups.com
Give the details of not able to migrate and someone might be able to help you 

Meanwhile refer to below doc and try again. 
https://www.digitalocean.com/community/tutorials/how-to-set-up-django-with-postgres-nginx-and-gunicorn-on-ubuntu-20-04


Regards,
Chetan Ganji
+91-900-483-4183


--
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/1c48e865-75c2-7c0a-5273-86c41f81f850%40stacktrace.dk.

Danny Gho

unread,
Dec 29, 2020, 11:46:36 AM12/29/20
to django...@googlegroups.com
Can you describe the error? Is there any error message you are getting?


Make sure that your pgsql port is open to local network/your Django server connection.

Sincerely yours,




Danny Gho
dannygho.com

--
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...@googlegroups.com.

Govind Kumar Yadav

unread,
Dec 29, 2020, 4:01:45 PM12/29/20
to django...@googlegroups.com
Like if I am trying to deploy a new project from beginning I am able to do that without any error but when I try to deploy my already existing project which works fine on my local windows machine with postgresdb it fails to migrate the data and pops error that relation "posts_post does not exist". Below one can find the attached screenshot of the error.
Please let me know that if it's possible to deploy a full fledged django webapp with al the data prepared on local host using postgresdb on Linux.
Regards,
Govind.
IMG_20201230_021419686.jpg

Kasper Laudrup

unread,
Dec 29, 2020, 4:10:29 PM12/29/20
to django...@googlegroups.com
Hi Govind,

On 29/12/2020 21.57, Govind Kumar Yadav wrote:
> Like if I am trying to deploy a new project from beginning I am able to
> do that without any error but when I try to deploy my already existing
> project which works fine on my local windows machine with postgresdb it
> fails to migrate the data and pops error that relation "posts_post does
> not exist".

Are you using postgres on Windows or which database are you using? It's
not really clear from what you're writing, but if you're using sqlite,
then this might help:

https://dev.to/coderasha/how-to-migrate-data-from-sqlite-to-postgresql-in-django-182h

It seems like this has nothing to do with the operating system but is
more of a database migration issue?

> Please let me know that if it's possible to deploy a full fledged django
> webapp with al the data prepared on local host using postgresdb on Linux.

It is. You just need to make it clearer what you have done to "prepare
all the data on localhost".

Kind regards,

Kasper Laudrup

Govind Kumar Yadav

unread,
Dec 29, 2020, 4:33:13 PM12/29/20
to django...@googlegroups.com
Initially my webapp was using sqlite and I tried migrate my data to postgresdb by following the same procedure as mentioned in the " Dev post " you just shared with me while I was deploying the webapp on nginx server but it failed with error "unknown field (s) (next_post, previous_post)".

After that I configured my project in postgresdb on my system from begining and added all the data in postgresdb so I could easily deploy my webapp, but when I tried to deploy this time I got the error message which I had posted earlier.
In simple words I'm not able to migrate in my already existing webapp(it's on postgresdb on my local machine too).
Regards,
Govind

--
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...@googlegroups.com.

Arisophy ISJ

unread,
Dec 29, 2020, 9:34:51 PM12/29/20
to Django users
Hi, Govind,

Did you see this page?


Is that situation similar to yours?

regards,
Arisophy

2020年12月30日水曜日 6:33:13 UTC+9 jayo...@gmail.com:

Govind Kumar Yadav

unread,
Dec 30, 2020, 2:14:56 AM12/30/20
to django...@googlegroups.com
Hi, Arisophy
No it's not the same case as I'm getting error while running "python manage.py makemigrations". But what I have gathered through this time is I need to empty the migration and cache folder as there is no error while creating a new project. I don't know why it's like that.
regards,
Govind

Reply all
Reply to author
Forward
0 new messages