Help with setup of laravel cmds on project deployment
Hello everyone so im hosting a laravel rest api but i cant seem to access the terminal and run cmds to seed the database etc, i want to seed the database on every start up
36 Replies
Project ID:
c93cd254-9d7c-42ba-ac53-835e0f60c9cc
c93cd254-9d7c-42ba-ac53-835e0f60c9cc
also now i get this issue for some reason
There's no terminal in railway
nor SSH connection
ye i thought imma just do it in the build step
Yep, add migration command to the start command
but now im getting this issue and i dont seem to quite understand why it is doing it
Just be careful with the seeder since it will seed everytime u build
does it not wipe the databse on new deploys?
Seems like its Railway related, just try again
No
aight imma try
Only if ur code does that, but Railway Dbs are persistent
tbh it just to host a quick thing not suppose to be useable
alright i retried now lets see
damn
it usually dont take this long with my other servers
it works now but it dont seem to run the migrations
do i need to make a complete new build step for this?
run the migrations on the start command
eg:
run migration && run start
i did this
@Medim i think this sis the same
i did it in here
yes, its the same
aight bet
its some how not working?
i served it but it serves to port 8000
what port was it that railway expected it to serve on?
i removed the start functions since i dont need them lets see what that does hehe
Do you have a PORT env var?
nawh
do i need one but it worked before?
it works now
Then it just wasn't 'there yet'
now im getting this issue wth
And I guess this issue didn't happen locally
?
nah
Hmm, I suspect your laravel app is missing some config for prod
But I never used Laravel in my entire life
hmm maybe
So I don't think I can help u there :copium: