Description of the problem - my user in the remote database Elephant does not have superuser rights (as far as I understand). I simply do not understand how these rights can be transferred to him in such a case?
Done - I tried to google how to solve this, but at the moment, as far as I understand, it is not possible to solve it through the Elephant interface itself.
How can it be done correctly?
#superuser to creat an issue
40 messages · Page 1 of 1 (latest)
- is there a reason why "remote" is mentioned? does that affect anything.
- Superuser as in, a django user with
is_superuserset to True? - Transferred implies a source and a target, or do you just mean given?
- what is the "remote database Elephant" and the "Elephant interface"? Do you mean Postgres, because the database logo is an elephant?
Yes, it is remote database as remote postgres db
Remote implies not local db but db existing in Internet server
Yes, I meant given. I just used translator to translate text from my native language
So i presume you mean your database user, correct?
How are you accessing the postgres interface?
Yes, database user
Via PgAdmin client
and do you have access to any other account on that database with superuser rights?
I have created one account for this db, using Google for registration
No other accounts at all
In my certain case I am rumminating on edge mean to solve this issue - totally tear down remote db and the repeatedly create just new one just the same content.
But I think as of now I can do it in other more simple and not extreme way
Can you explain what you mean by this bit?
does not have superuser rights (as far as I understand).
Do you mean a Django user, or do you mean a postgres user?
Do you mean your Django app can't connect to the database and create tables, or do you mean your app is working but a user in the Django user's table doesn't have the is_superuser flag set?
User for remote database
The user Django users to connect to Postgres as?
User whome I put in settings file as database user for remote database
Okay. So if that user isn't a superuser, what problem is that causing?
Migrations unable to run?
Issue is that I can't run tests now at least
Tests shouldn't talk to the production database...
What?
At the crux I put test directory on GitHub as well, and those test should be available for other people who will observe my project - to run those tests by those people
Well I see your point. And in the essense it's strange that it showed such message, because test running should create temporary test database which is separate from main db
I mean official documentation is important but every issue is individual and requires clarification how to use rules in this case
Half the skill of being a decent developer is being able to read and understand documentation, and then apply that to your specific use case.
What "remote Postgres" platform are you using, and have you checked their docs for how to create users with the privileges you need as detailed in that documentation about test databases on Postgres?
ElephantSql
Important Notice: ElephantSQL is shutting down. Read all about it in our End of Life Announcement
You probably want to look into moving from that…
Are you using the free tier of ElephantSQL?
Free plan, yes
In my case I can't. Well, as alternative you can recommend me another solid db, such as Elephant with free tiers
Then that's likely your issue. It seems that that plan doesn't let you create additional databases per user, which Django needs to be able to do when running tests.
Besides Elephant could you recommend another one with free tiers
No idea I'm afraid. I don't use any hosted Postgres platforms.