Spacelift support for install stacks is gated behind a feature flag. Reach out to Nuon to enable it for your org.
- Blueprint — publish a Spacelift blueprint and use the web UI to provision the stack.
- Terraform — apply a generated
spacelift.tfand use the Terraform provider to provision the stack.
nuonco/install-stacks modules over raw Git, so no Spacelift VCS integration or GitHub App install is required.
How it works
Provisioning with Spacelift is a hand-off between you and your customer:- You create the install. The install workflow pauses at the await install stack step.
- On that step’s Spacelift tab, you copy the blueprint YAML or download the Terraform files.
- You send them to your customer.
- Your customer provisions the stack in their Spacelift account, into their cloud account.
- The stack boots up the runner. Once the runner connects, the await install stack step completes and the install proceeds — no further action needed on your side.
Prerequisites
Your customer will need the following in order to use Spacelift.- A Spacelift account with permission to create blueprints and stacks.
- The cloud integration set up for the cloud account they want to install your app in.
Using a blueprint
Follow these steps to provision a stack using a Spacelift Blueprint.1
Create an install
Create an install as you usually would, and wait for the provision workflow to get to the await install stack step.
2
Send your customer the blueprint
On the await install stack step, open the Spacelift tab and copy or download the blueprint YAML.
Send this to your customer.The remaining steps are for your customer.
3
Create the blueprint
In Spacelift, go to Blueprints → Create blueprint and paste the YAML from your vendor as the template body.
The template is configured to put the stack in the
root space by default.
Edit the space: line while it’s a draft if the stack should live elsewhere.4
Publish it
Click Publish to move the blueprint from draft to published.
Once published, the blueprint cannot be edited.
5
Create a stack and fill in the inputs
On the published blueprint, click Create stack and fill in the inputs and secrets.
Click Create to create the stack.
6
Attach cloud credentials
Open the new stack’s Settings → Integrations. Attach the cloud integration to grant Spacelift access to the cloud account.
7
Provision the stack
Trigger a run.
This will provision the Nuon stack.
Once the runner phones home, the await install stack step in Nuon will complete.
Using terraform
Follow these steps to provision a Nuon install stack using the Spacelift Terraform provider.1
Send your customer the files
Click Download all (.zip) on the Spacelift tab to get
spacelift.tf, inputs.auto.tfvars, and
secrets.auto.tfvars as a single zip (or download them individually), then send them to your customer.The remaining steps are for your customer.2
Configure `spacelift.tf`
Unpack all three files into one directory. In
spacelift.tf, set the space_id variable’s default to the
Spacelift space this stack should live in.3
Authenticate with GCP
By default, the config attaches Spacelift’s GCP integration to the stack — a dedicated service account created
during the apply. If you already manage your own GCP integration, set
attach_gcp_service_account’s
default to false in spacelift.tf.4
Configure `inputs.auto.tfvars`
Fill in the inputs in the
inputs.auto.tfvars file.
Leave this file alongside the stack if you want to manage these values in version control.
Alternatively, you can save the contents to a mounted, non-secret file in Spacelift.5
Configure `secrets.auto.tfvars`
If saving this as a secret mounted file, fill in the secrets in
secrets.auto.tfvars.
Alternatively, store the secret values in a secret store and pass them to terraform using environment variables.6
Authenticate the Spacelift provider
The
spacelift-io/spacelift
provider needs Spacelift API credentials.
If the terraform is being run within Spacelift, then these will automatically be populated in the environment.
Otherwise, configure authentication for the Spacelift provider.7
Apply the stack
Initialize the terraform workspace and apply.
8
Trigger the first run
Trigger the first run.
This will provision the Nuon stack.
Once the runner phones home, the await install stack step in Nuon completes.