8000 railway.com one click deployment problem | Backend started at 8080 · Issue #632 · gitroomhq/postiz-app · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

railway.com one click deployment problem | Backend started at 8080 #632

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tamilarasi-tech opened this issue Feb 27, 2025 · 13 comments
Open

Comments

@tamilarasi-tech
Copy link
Contributor
tamilarasi-tech commented Feb 27, 2025

After deploying using the Railway template, everything works as expected. However, the backend service is mapped to the default port 8080, while the application requires PORT=3000.

Expected Behavior:
The backend should automatically map to PORT=3000 to match the expected configuration.

Actual Behavior:
The backend is mapped to PORT=8080, causing misconfiguration issues.

Suggested Fix:
Modify the template's environment variable PORT to 3000 to ensure correct deployment.

[Nest] 175 - 02/27/2025, 6:47:23 PM LOG 🚀 Backend is running on: http://localhost:8080/

@egelhaus
Copy link
Collaborator

We do not offer support for Railway, as it isn't listed in the Documentation or anything, that template is just there to get the SaaS Version running, not for OSS Deployers, if you want to use Railway you're going to have to do it yourself with no support.

@tamilarasi-tech
Copy link
Contributor Author

I'm happy to take issue #340 and work on the documentation and code changes.

@egelhaus
Copy link
Collaborator

Hey, if you could do that, that would be great, I'm happy to assign this to you.
@tamilarasi-tech

8000

@egelhaus egelhaus reopened this Feb 27, 2025
@egelhaus
Copy link
Collaborator

You need to comment once on the Parent Issue to let me assign it to you.

@Azadbangladeshi-com
Copy link

@chad-syntax
Copy link

Hey folks, I was actually working on this off-and-on the past couple of weeks, I was able to fix the issues and have it deployed on my own railway (https://postiz.chadsyntax.com/). I opened this PR #634, happy to work together to get it merged.

@tamilarasi-tech
Copy link
Contributor Author

Happy to work together @chad-syntax . Working on the docs for Railway One Click Deployment.

@chad-syntax
Copy link

Happy to work together @chad-syntax . Working on the docs for Railway One Click Deployment.

Great, I assume that means we need to add some info the this repo's README and submit another PR to https://github.com/gitroomhq/postiz-docs?

I'm thinking we can either just say: "here's the railway template, just click this link and it will fill in all the settings and deploy right away"

OR "here are the full steps on how to set it up from scratch" (still pretty straightforward)

@leemuljadi
Copy link
leemuljadi commented Apr 21, 2025

Hey guys @tamilarasi-tech @chad-syntax , how is it going with the railway one click deployment? I tried deploying using this template below but cant even sign up? how did you guys get around it?

Image

and got this error:
Image

@chad-syntax
Copy link

I honestly do not know, in another thread I was asked if we could change the template so I wasn't the referrer, as Railway gives monetary kickbacks to the template owner. So that requires the postiz owners to make the template.

I was able to get it running on my own by standing up a service from the docker image, a psql, and a redis using the environment variables I list here in the docs repo.

(Though I'm still not 100% sure if the PORT=5000 env var being present helps or hurts due to some other port related changes recently, if it fails to deploy you could remove PORT and set the service port manually in the railway config.)

@leemuljadi
Copy link
leemuljadi commented Apr 22, 2025

@chad-syntax thanks for your response. is this the env that you use? pages/installation/railway.mdx
I also use the port=5000 for the public domain.

@chad-syntax
Copy link

@chad-syntax thanks for your response. is this the env that you use? pages/installation/railway.mdx
I also use the port=5000 for the public domain.

Yes those are the env vars I use, except for the PORT=5000, let me explain further.

Setting PORT to 5000 resulted in two things

  1. Railway binds the service to that port for hosting
  2. The postiz nodejs back-end starts on port 5000 which we do not want, it needs to run on 3000 so caddy can run on 5000 and proxy traffic to 3000

But it has been a couple months since last I tested this. The safest option is to omit the port env var and manually bind the service to 5000 in the railway dashboard. It should detect caddy and suggest binding to 5000.

Now if other changes were introduced that are causing new issues, I can't say. If I have some time in the near future I'll see if I can get it running from scratch again.

@leemuljadi
Copy link

Thanks @chad-syntax, yes I managed it working.

  1. The default env in Railway is not accurate so need to update those according to the documentation.
  2. Did the port binding on port 5000 in Railway UI.
    Btw I found out that the one in Railway does not have the full fucntionalities like the paid version (like refererral, etc.), do you reckon?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants
0