Need Help with Caddy Configuration on New VPS

0
8
Asked By TechWiz42 On

I'm moving to a new VPS since my old provider is shutting down. Right now, my domain name still points to my old VPS, so I'm only able to access my apps on the new VPS through its IP address and specific port numbers. However, I'm having trouble accessing my applications. For instance, I have a Docker container named `my_app` that's supposed to work on ports 8018:80. In my Caddyfile, I set it up like this:

111.222.333.444:8018 {
reverse_proxy my_app:80
}

But I can't reach the site at [https://111.222.333.444:8018](https://111.222.333.444:8018). I'm not sure if I should change the last line to

reverse_proxy localhost:80

or something else entirely. I want to make sure I can get at least one container up and running before I update my domain name and subdomains to point to the new IP. Any help would be greatly appreciated!

3 Answers

Answered By ClearCoder98 On

It sounds like there's some confusion here. You have two VPSs: the old one, which your domain currently points to, and the new one where you're trying to set things up. From what you've described, it seems like you're trying to access your app on the new server using its IP but are having problems with the reverse proxy setup in Caddy.

Answered By ServerSavvy1 On

Caddy is usually pretty straightforward to set up, but let's make sure everything's configured correctly. A few things to check: 1. Are you running Caddy inside Docker as well? 2. Is Caddy configured to listen on port 8018 for incoming traffic? 3. Double-check your firewall settings to ensure that it allows traffic through this port. Once those are clear, you should be on the right track.

Answered By DevNinja8 On

Your issue might be related to the firewall settings on your new VPS. Make sure that the firewall is allowing traffic on port 8018. Also, you could temporarily modify your local hosts file to route your domain name to your new VPS IP for testing purposes.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.