Front End deploy, "Application failed to respond" Vite
Hello! I am deploying a simple app on Railway, had issues with same error when deploying back but article on Railway refering to whis error worked for me. Anyway, now I am getting this same error when deploying front. I changed vite start command with start: vite --host and have tried with start: vite --host 0.0.0.0, and as I did not found any article yet referring to this error on front-end I come here trying to solve π On deploy Logs I get this:
[email protected] start
vite --hostVITE v4.5.0 ready in 236 ms β Local: http://localhost:5173/ β Network: http://172.17.1.98:5173/ Proyect-ID: 15962663-323b-4e7f-882b-b3c2bdca0c35
Solution:Jump to solution
https://github.com/brody192/vite-react-template
you should just be able to copy the nixpacks.toml and caddyfile from this repo into your repo...
9 Replies
Project ID:
15962663-323b-4e7f-882b-b3c2bdca0c35
you are trying to run your vite app in development mode, definitely don't wanna do that
Solution
https://github.com/brody192/vite-react-template
you should just be able to copy the nixpacks.toml and caddyfile from this repo into your repo
I saw It but thought I needed to change a lot of things. Will give It a try and be back. Ty
should just be as simple as copying those two files
Did It, building looks fine but now I am getting a npm command not found, tried to change It but the message kept. Decided to remove the starting command on railway and I am getting this on the Deploy Logs:
using provided configuration
2023/10/24 16:36:32.733 WARN admin admin endpoint disabled
2023/10/24 16:36:32.733 WARN http.auto_https automatic HTTPS is completely disabled for server {"server_name": "srv0"}
2023/10/24 16:36:32.733 INFO tls.cache.maintenance started background certificate maintenance {"cache": "0xc0005a3700"}
2023/10/24 16:36:32.733 INFO tls cleaning storage unit {"description": "FileStorage:/root/.local/share/caddy"}
2023/10/24 16:36:32.733 INFO tls finished cleaning storage units
2023/10/24 16:36:32.734 INFO http.log server running {"name": "srv0", "protocols": ["h1", "h2", "h3"]}
2023/10/24 16:36:32.734 INFO serving initial configuration
removing the start command from the service settings was the right move, what seems to be the problem now? those logs looks perfectly fine to me
(please enclose code or logs in triple back ticks)
Ohm I was getting application not found for 2 mins. Now that I re-check It seems that is working just fine. Thank you so much. Marking as solved.
no problem!