Golang

Is it possible to use Golang on your hosting (paid)

1 Like

From what I can find in their demo, there is no support for Golang on Premium Hosting I think.

2 Likes

I think the way web hosting works is fundamentally incompatible with how Golang programs are run.

With PHP web hosting, the idea is that you upload your website code to the server, and the server provides the runtime environment that runs the application code when the request comes in.

Some premium hosting can support other languages such as Python, Ruby and Node.js too. But, like PHP, they are interpreted languages, not precompiled, and some limitations apply because the runtime environment is once again provided by the hosting provider (usually through Phusion Passenger). And usually this environment is more a lot restricted than if you were to run the application yourself.

Compiled languages, such as Golang, are compiled to a binary package, where the package itself includes everything it needs to run, and this program is expected to be run continuously.

To run a Golang program, you’ll essentially need something that’s language agnostic and lets you bring your own runtime environment. A VPS is one way to do that, but a more managed service that that lets you just run a Docker container would work too.

But those are fundamentally different services because you are responsible for a larger part of the stack. This enables more flexibility (such as running Golang), but also increases your responsibility to setup and maintain it properly.

11 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.