Website Doesn't Stay Online Even With Always Online On

I’m working on a r/place I forked and everything was going well until I realized my project doesn’t actually keep the website online forever. I have the Repl on always online too.

To start the website, I go into the shell and run this command:

cd place/cmd/place
./place -root ~/NewTest/place/web/root -load place.png

(You would run a different command if it’s your first time)

When I then close the Replit tab, the entire website itself turns off. Any ideas to how I could fix this?

Try setting the command as the run command in the .replit file. (processes in shell tabs are terminated when you close the tab)

1 Like

Replit Always On does not keep Repls awake 24/7, instead, when your Repl goes to sleep, it will immediately wake back up with Always On.

They were running it from the shell tab, so it was exiting when they closed the page

1 Like

So would I turn

run = ["./main"]

entrypoint = "main.go"

Into this


run = ["./place -root ~/NewTest/place/web/root -load place.png"]

entrypoint = "place/cmd/place"

?

Try this:

run = "place/cmd/place -root ~/NewTest/place/web/root -load place.png"

(The entrypoint sets the file displayed by default, not the initial directory)

image

Try place/cmd/place/main instead of place/cmd/place, then

1 Like

Can you run ls place/cmd/place and show us the output?

1 Like

image

1 Like

Same issue :frowning:

1 Like

Try place/cmd/place/place instead. You may need to run chmod +x place/cmd/place/place if it’s not working.

Sorry, I missed that. Try @youngchief 's suggestion

1 Like


Want me to still use chmod +x place/cmd/place/place?

1 Like

Try doing place/cmd/place/place -root ~/NewTest/place/web/root -load place/cmd/place/place.png.

2 Likes


:o

2 Likes

Now if I were to close Replit, would this stay?

1 Like

If you encounter any more issues. Feel free to ask for help!

1 Like

Yes. :slight_smile: (Try it, it should work)

Just wondering, how much disk space is your repl using? I’d love to try deploying that on my website

2 Likes

image

1 Like