Build your Golang code with Go Modules

go modules 1

You can now build your go projects with go modules! Please take a look at our Go modules documentation.

At the begining of Go's adoption, the build tools available were goinstall and then go get. It worked simply, but versioning was not managed. Developers started vendoring libs, it started to be a bit messy. The Go community addressed this problem with different third-party builds and dependencies management tools. And then came the official answer from the Go team: Go Modules. And we support it on Clever Cloud \o/.

How to Deploy

The default build tool is still go get. So to choose go modules you will need the following environment variable: CC_GO_BUILD_TOOL=gomod

Please make sure your go.mod file is at the root of your repository alongside main.go. If you have a different entrypoint you can specify it with the environment variable CC_GO_PKG=./path/to/entrypoint.go

If you follow those two advices, everything should go well and you will have your deployed go application on Clever Cloud. We hope you will enjoy using it. Please let us know if you have any other suggestions to make our golang support better.

Happy coding!

Blog

À lire également

What Is the SAML 2.0 Authentication Protocol Used For?

SAML 2.0 (Security Assertion Markup Language) is an open standard based on XML (eXtensible Markup Language) that enables Single Sign-On (SSO) across multiple domains. It delegates authentication to a central identity provider, which sends each application a signed “assertion” proving the user’s identity, without requiring the user to re-enter or share their password with each application.
Engineering Features

UP Programme: meet the 4 startups joining Clever Cloud’s sixth cohort

Kernel, Nijal AI, Qiplim and Arkan are joining the sixth cohort of Clever Cloud’s UP Programme.
Company

French Managed Kubernetes: What Are the Alternatives to Hyperscalers in 2026?

French managed Kubernetes services provide organisations with European alternatives to AWS EKS, Google GKE and Azure AKS. OVHcloud, Scaleway and Clever Cloud now offer such services on infrastructure located in France or elsewhere in Europe. However, choosing a French managed Kubernetes service involves more than server location: the infrastructure model, the division of operational responsibilities and integration with other cloud services are equally important.
This article compares the three offerings and outlines the key criteria for making a decision.
Engineering Features