Skip to main content

Configuration

To install an app template on GCP, configure it to use a GCP sandbox and runner. We provide a GKE sandbox you can use to get started, which provisions a GKE cluster and the IAM bindings the runner needs. Create inputs for the public and private domains, since those will be different for each install.
sandbox.toml
sandbox.tfvars
runner.toml

Installation

When you create an install, Nuon generates a Terraform install stack. Your customer applies it in their GCP project to create the runner and base infrastructure. They can run Terraform themselves or through Google Cloud’s Infrastructure Manager.

Create an Install

In the Nuon dashboard, open the Installs tab, click Create Install, and select the app you want to install. This starts a provision workflow. Its Await install stack step shows how to apply the stack, with the TF Module tab selected by default.

Install the Stack

The recommended path is the published nuonco/stack/gcp module. Your customer adds the snippet from the TF Module tab to their own Terraform project, sets their Nuon credentials and secret values as environment variables, and runs:
On the first apply, the snippet passes project_id and region to the module, because the control plane hasn’t recorded the install’s project yet. Your customer can drop them once the install is provisioned. See Provision Stacks with a Terraform Module for every step, including credentials and secrets.
The Terraform tab still offers the legacy flow: clone install-stacks/gcp and apply generated inputs.auto.tfvars and secrets.auto.tfvars files. See Provision Stacks with Terraform.

Try it with a sample app

We maintain gke-simple, a sample app that uses the GKE sandbox to deploy a whoami workload with a certificate and load balancer. To try it:
  • Install the CLI
  • Clone the example apps repo
  • cd into the gke-simple directory
  • Run nuon auth login
  • Run nuon apps create -n gke-simple
  • Add branches/main.toml with a [public_repo] block pointing at nuonco/example-app-configs, directory gke-simple, branch main (see Configure app branches)
  • Run nuon branches sync --file branches/main.toml, which creates the branch and starts its first run
  • Open the Nuon dashboard and create an install

Updating

If you make changes to the install stack template, the install must be reprovisioned to update the stack.
  1. From the install’s Overview page, click on “Reprovision install” in the “Manage” drop-down menu. This will trigger a reprovision workflow.
  2. A new stack version is generated.
  3. Your customer runs terraform apply again. With the module, the new version is picked up on the next plan. With the legacy flow, send them the updated inputs.auto.tfvars and secrets.auto.tfvars files first.
See Updating the stack for input, secret, and role changes.