Deploy Medusa Backend to Railway Difficulty creating an administrator and his password

I did everything according to the documentation https://docs.medusajs.com/deployments/server/deploying-on-railway Then I went into the console and wrote -railway login -railway link I chose the project I needed and its GitHub repository wrote railway shell And entered the command from the documentation railway run npx medusa user --email [email protected] --password supersecret but nothing happens since all this happens locally as I understand it. I am sure that this should work, I saw people here who work with this framework and set up a password.
No description
26 Replies
Percy
Percy8mo ago
Project ID: 8b1e4ae6-f221-4948-a158-23868f94c7db
testerOne
testerOne8mo ago
8b1e4ae6-f221-4948-a158-23868f94c7db
Brody
Brody8mo ago
you have a error printout, please get that sorted
testerOne
testerOne8mo ago
I took a workaround by adding this command. She actually created the records that I needed. But as I understand it, I have no connection with the database and radish. Could you help me with this? When I created the project I used the variables in the 2nd image But I have these messages in the 3rd image
No description
No description
No description
testerOne
testerOne8mo ago
As far as I understand the links are correct
No description
No description
No description
Brody
Brody8mo ago
going forward please do not treat either the build or start command fields as just a place to run any arbitrary command, that is far from the proper use. you would have wanted to run that command locally though either railway run or railway shell moving on
testerOne
testerOne8mo ago
OK, thank you. But now I have entries in the database but cannot log in using the created password and user. Problems connecting to the database?
Brody
Brody8mo ago
your service variables look correct, but that doesn't mean those are the exact variables you are using in your code, so please show me how you are connecting to postgres in your code (we are going to work on one database at a time)
testerOne
testerOne8mo ago
No description
testerOne
testerOne8mo ago
Also, in the same file. Is this what you were asking about?
No description
Brody
Brody8mo ago
have you printed these environment variables to make sure they are correct?
testerOne
testerOne8mo ago
printed ?
Brody
Brody8mo ago
console.log
testerOne
testerOne8mo ago
When deployed locally, everything was fine..
Brody
Brody8mo ago
something is misconfigured somewhere, try to console log the environment variables
testerOne
testerOne8mo ago
Okay, I'll try now. But shouldn't there be an error here? writes that Database initialized
No description
Brody
Brody8mo ago
somewhere redis is not configured
testerOne
testerOne8mo ago
yes, I can configure it after. The local project was without redis and all database connections worked
Brody
Brody8mo ago
where are the postgres related errors?
testerOne
testerOne8mo ago
I don't see them And I don’t understand why I can’t log in with my username and password. Which are already in the database
Brody
Brody8mo ago
how have you confirmed that?
testerOne
testerOne8mo ago
They are not in the log
Brody
Brody8mo ago
im not sure how that quite answers the question
testerOne
testerOne8mo ago
I'll try to solve it somehow. Thanks for your time
testerOne
testerOne8mo ago
If I have entries in the data and these messages So the database is connected, right?@Brody
No description
No description
Brody
Brody8mo ago
it means migrations have been ran
Want results from more Discord servers?
Add your server