QODDI DOCUMENTATION
Go
Last updated

Qoddi automatically builds your Go app from your code.
In order to do that, Qoddi uses buildpacks to detect and build your app automatically.
You can fork or build this repository to get started with Go on Qoddi
Before Building your app
Commit go.mod, go.sum when dependencies generate it, your source, and a Procfile. Use Go modules and run go mod tidy locally before committing dependency changes.
Create your app on Qoddi
Create a new app and link it with your repository using SSH keys.
Read this article for a detailed procedure or check this video :
go.mod
A root-level go.mod identifies a module-based Go project. A minimal example for an app tested on Go 1.27 is:
module example.com/my-app
go 1.27Use your own module path. The current classic Heroku buildpack reads the go directive; a // +qoddi goVersion comment is not a universal requirement. Its selection order is GOVERSION, then a // +heroku goVersion comment, then the go directive, then its fallback.
See the buildpack version-selection source. Keep any explicit override consistent with the app’s minimum Go version.
Overriding the Go Version
As of November 2, 2026, the maintained Go lines are 1.26 and 1.27. Heroku’s classic version manifest maps go1.26 to 1.26.10 and go1.27 to 1.27.3. Its fallback is still go1.25, so select a maintained line explicitly.
For the classic buildpack, set GOVERSION=go1.27 in the build environment to override the file-based choice. Rebuild and check the compiler version in the log. Go supports a release until two newer major releases exist; see Go’s release policy.

Runtime references checked November 2, 2026. Available binaries and defaults depend on the selected Qoddi builder and stack; confirm the resolved version in the build log.
Passing a Symbol to the linker (and optional string)
Qoddi supports the Go linker’s ability (-X symbol value) to set the value of a string at link time. This can be done by setting $GO_LINKER_SYMBOL and $GO_LINKER_VALUE in the application’s config before pushing code. If $GO_LINKER_SYMBOL is set, but $GO_LINKER_VALUE isn’t set then $GO_LINKER_VALUE defaults to $SOURCE_VERSION.
This can be used to embed the commit SHA, or other build-specific data directly into the compiled executable.
Other Builder Behavior
The classic Go buildpack recognizes GO_INSTALL_PACKAGE_SPEC to select a package such as ./cmd/server, and GO_INSTALL_TOOLS_IN_IMAGE=true when runtime access to the compiler is necessary. The normal image contains compiled binaries without the toolchain.
Use standard GOPROXY, GOPRIVATE, and CGO variables as needed. These build-time options are implementation-specific; see Heroku’s Go build configuration.
Procfile
Start the compiled executable by its actual installed name. For a package ./cmd/server producing bin/server:
web: bin/serverThe executable name follows the main package or build configuration, not necessarily the module name. Verify the output in the build log. Have the server bind to 0.0.0.0 and Qoddi’s configured PORT.
Add Go Packages
If go.mod file is present inside the app root folder, Qoddi will build the image with additional packages. The proper way to use Go packages is described here.
Default Behavior
By default, your Go app is routed to the 8000 port of the container. If you need to change the instance port of your app you can do it from the app settings page.
Note: you can set up any container port but Qoddi will only route 80/443 traffic to your app. Qoddi’s apps are not reachable from the outside of Qoddi on any other port.
Sessions handling
Since Qoddi supports dynamic local storage (called Virtual Disks) that are shared between the same app even if it’s working on different hosts (members of the same stack), you can create a virtual drive inside the app settings to store that information.
You can also use the Gorilla toolkit to store the sessions on the client-side. Make sure to create the environment variables SESSION_AUTHENTICATION_KEY and SESSION_ENCRYPTION_KEY before you build your app.
Launch a Console Command
Please check this article on how to launch a command directly to your running app. This can be used to perform database migrations, launch local scripts, or perform database backups.
Ephemeral Disk
Contrary to Marketplace apps that can use Qoddi’s virtual disks features to store and retrieve persistent data, apps that are created from code use an immutable file system.
You can write data locally, for instance, to process files temporarily during your application life, but the data written into your app’s disk is not persistent and gets wiped out after your app restart.
All apps restart at least once every 24 hours, to apply a new setting or to deploy a new build.
To store data and keep it persistent you can use external services like Amazon S3 or Wasabi, an S3 compatible storage service with very affordable pricing.
Add a domain name
Please check this article for a detailed method on how to use your domain name with Qoddi apps.
Define environment variables
Note: Environment variables set in your app settings are injected during the build process. If the build of your app needs to use an env variable make sure to set it before requesting the build.
Qoddi lets you externalize the configuration of your app : the Qoddi’s cluster will automatically injects the data when the app start or restart.
Environment variables can include any external data your app needs to run like external resources, databases addresses, encryption keys, etc…
To add an environment variable, access your app settings and click “Add ENV Variable” :

Enter the key (like DATABASE_USER) and the value and click “Add”. Qoddi will automatically add your environment variable and restart your app after a one-minute delay (to let you add more env variables if necessary without restarting the app each time a new variable is added).
Provision a database
Qoddi Marketplace includes all popular datastore engines including Mysql, Postgres, MongoDB, and Redis.
To add a database to your app, click on Marketplace and select the database you want to run, then create the new app database inside the same stack as your Ruby app.
Once the app is running, visit the database app’s settings and retrieve the “internal name” :

Use this internal name as you would use a server address, for instance for MySQL this name replaces the usual “localhost”. Some scripts require you to add the database port at the end of the server address. Qoddi uses a common port for each database software, for MySQL it will be 3306 and you can write it like that inside your scripts: internal-name:3306
Postgres usually uses credentials sent inside the login URL, like that : postgres://<user>:<password>@<internalname>:5432/<database>
The login and password information is available inside the Environment Variables of the database app.
Note: Qoddi’s datastores run on a private and encrypted network. Therefore SSL support is deactivated for all datastores available on Qoddi. Ensure that your code doesn’t require using SSL before deploying your app.
Reach your app from another app
Inside your app stack, you can reach any other Qoddi app member of this stack on any port. Qoddi automatically routes the traffic internally and opens the appropriate port. By opposition, your app is only reachable on ports 80/443 from outside of Qoddi.
To reach your app internally, retrieve the internal name from your app settings page :

This name can be used to reach your app from another app inside the same stack. Use it in any form that works with your script :
http://<internalname>
<internalname>
http://internalname>:port
Note: https:// is not available, all the traffic inside apps is already encrypted by the cluster.
Encryption
Qoddi uses at rest encryption for the app virtual disks, build images, and encrypted transport from inside the cluster. To make sure the traffic is encrypted between your app and the browser of your users you can set up SSL certificates for any domain name connected to the app (including the Qoddi’s default domain name).
Scale your App
From your app settings you can scale your app vertically and horizontally: by upgrading the app size (refer to our pricing for app sizes details) or by adding more nodes.
Additional nodes will run another copy of your app inside another Qoddi server located inside the same cluster (same geographical location). Traffic is automatically sent to the least occupied node by Qoddi’s load balancer.