The sections below contain information on the types of node that you can include in your template, how they are used, and their schema.
The nodes are divided into the following categories:
- Flow control contains nodes that are to be run in sequence or parallel
- Team resources specifies team-level resources, such as projects and cloud integrations
- Project resources specifies a service, job, addon, or other resource to be created or updated
- Actions specifies an action to run on a resources, such as starting a build, running a job, or executing a command
- Conditions hold the template run while until the status of a resource or action is returned
Flow control nodes
Flow control nodes contain resource and action nodes, and determine in what order they are executed. You can click the switch button in the workflow node to change to a parallel or sequential flow.
Sequential workflows will execute nodes from first to last, and will wait until a node has succeeded before executing the next. Parallel workflows will execute all the nodes contained within in them at the same time.
Workflows can be nested. For example, you can run two sequential workflows simultaneously within a parallel workflow, within another sequential workflow.
If a node contained in a workflow fails, the entire workflow will be marked as failed.
Project context
You can specify the project context for a workflow which will be inherited by all the nodes contained within the workflow. This context can be overridden by setting the context directly on nodes or other workflows nested within this workflow.
Error fetching template node schemaTeam resource nodes
Team nodes create and update resources and integrations on the team level. They do not require a project context to run.
| Kind | Description |
|---|---|
| Project | Create or update a project |
| BYOC integration | Create or update a cloud provider integration |
| BYOC cluster | Create or update a cluster and node pools |
| Subdomain path | Create a path for routing on a subdomain |
| Tag | Create a new tag in the team for tagging resources |
| Custom plan | Create a custom resource plan in the team |
| Secret inheritance | Merge multiple global secrets with priority ordering |
Project
Error fetching template node schemaBYOC integration
Error fetching template node schemaBYOC cluster
Error fetching template node schemaSubdomain path
Error fetching template node schemaTag
Error fetching template node schemaCustom plan
Error fetching template node schemaSecret inheritance
Error fetching template node schemaProject resource nodes
Project resource nodes can be used to create or update services, jobs, addons, and other resources on the Northflank platform. They can also be used to trigger builds, run jobs, and schedule addon backups.
Project resource nodes require a project context to run. The context can be set directly on the node or inherited from a parent workflow.
| Kind | Description |
|---|---|
| Combined service | Create or update a combined service |
| Build service | Create or update a build service |
| Deployment service | Create or update a deployment service |
| Cron job | Create or update a cron job |
| Manual job | Creates or update a manual job |
| Addon | Creates or updates an addon |
| Secret group | Creates or updates a secret group |
| Pipeline | Creates or updates a pipeline |
| Volume | Creates or updates a volume |
To enable CI/CD and build from private Git repositories you must have a Git account linked to your Northflank team. To deploy images from a private container registry you must add your registry credentials to your team.
Combined service
A combined service will automatically build and deploy the latest commit for the selected branch when it is created.
Error fetching template node schemaBuild service
You must trigger a build using a start build node to deploy from a build service later in the template. Otherwise, a build will only be triggered when a commit matching the build rules is pushed.
Error fetching template node schemaDeployment service
You can link a deployment service to a build service or deploy an image from a container registry.
If you are deploying from a Northflank build service you can toggle between deploying the latest build or the latest commit from the build service.
Latest build will deploy whatever the service has build most recently, regardless of the commit age. Latest commit will deploy the most recent commit to the branch that has been built by the service.
Error fetching template node schemaCron job
You can deploy a job using an image from a container registry or one built by a Northflank build service.
You can also build and deploy an image in a job by linking it to a Git repository, and create a build to deploy using a start build node.
Error fetching template node schemaManual job
You can deploy a job using an image from a container registry or one built by a Northflank build service.
You can also build and deploy an image in a job by linking it to a Git repository, and create a build to deploy using a start build node.
Error fetching template node schemaAddon
You can make an addon's connection details available by linking them in a secret group node. An addon must be running to execute a backup or restore, you can use a condition node to check before performing actions on an addon.
Fork an addon
You can fork an addon from an existing project, or one created earlier in the template using a reference. The addon must have a backup available created from the same major version.
You can use latest to use the most recent backup, but if no backup exists the template run will fail.
Upgrade an addon
You can enable upgrade on version mismatch to allow a template to trigger an upgrade for an existing addon (disabled by default). If the addon version specified in the template is greater than the version of the existing addon, the addon will be upgraded. Addons must follow the upgrade path and cannot skip major versions. For example, to upgrade an addon from version 14 to version 16, you must first run the template with version 15 specified before updating to version 16.
Error fetching template node schemaSecret group
Error fetching template node schemaVolume
A running service will be restarted when a volume is attached to it.
Error fetching template node schemaPipeline node
Pipeline nodes are used to create a pipeline in a project and populate the stages of the pipeline with deployment services, jobs, and addons.
You can also define a preview environment and release flow templates for each stage of the pipeline using the visual editor within the pipeline node.
References, arguments, and functions in nested templates
Normally composed references, arguments, and functions will not be resolved in release flow or preview environment templates in pipeline nodes when the template is executed. This is to preserve their functionality in the release flow and preview templates when they are created.
If you want to include references, arguments, or functions that will be executed when the template runs, so that the values are resolved in the release flow and preview environment templates when they are created, you can prefix them with template.
For example:
"${refs.build.branch}"would become"${template.refs.build.branch}""${args.SECRET}"would become"${template.args.SECRET}""${fn.randomString(64)}"would become"${template.fn.randomString(64)}"
Preview environment
The pipeline specification can include preview, a node with the kind PreviewEnv. The spec for the PreviewEnv node includes apiVersion and spec, where spec is the content of the preview environment template.
- {object}preview
kind
stringThe kind of node.one ofPreviewEnvspec
{object} requiredThe preview environment template specification.
Release flow
Release flow template specifications can be included in pipeline stages.
- {object}releaseFlow
kind
string requiredThe kind of node.one ofReleaseFlowspec
{object} requiredThe release flow template specification.
Action nodes
You can define actions to take on existing services, addons, or Git services.
| Kind | Description |
|---|---|
| Run backup | Performs a backup on an addon |
| Job run | Runs a job with the specified configuration |
| Start build | Triggers a build in a service or job, from a branch or a specific commit |
| Run action | Performs the action contained within the node |
Run backup
An addon must be in a running state to run a backup successfully. You can use a condition node to ensure an addon is ready before the backup node runs.
Error fetching template node schemaRun job
Start a job run. The job must have a build or image available.
Error fetching template node schemaStart build
You can trigger builds in build and combined services, and jobs that deploy from version control.
Error fetching template node schemaRun action
The run action node can be used to perform actions in services, jobs, addons, and VCS (version control system) accounts.
| Kind | On resource |
|---|---|
| Restart | Service or addon |
| Execute command | Service or job |
| Restore addon from backup | Addon (with available backup) |
| Clone repository | Linked VCS account |
Commands in action nodes do not invoke a shell by default. Learn more about executing commands in action nodes.
Error fetching template node schemaCondition nodes
You can use condition nodes to check the status of a resource or action in a template or in an individual workflow. The workflow or template will continue to run until the condition is met, or until it times out.
In a sequential workflow the condition will stop following steps from running until the condition is met. In a parallel workflow all the steps will run, but the workflow will not be marked as completed unless the condition is met.
Below is a list of checks you can include in your template.
| Kind | Description |
|---|---|
| Running | Check a service, addon, or BYOC cluster is running |
| Success | Check a job, build, or addon backup has completed successfully |
| VCS | Check that a repository has been created |
| Kind | Description |
|---|---|
| Service | Check a service is running |
| Addon | Check an addon is running |
| Addon backup | Check an addon backup has completed successfully |
| BYOC cluster | Check a BYOC cluster is running |
| VCS | Check a Git repository has been cloned successfully |
| Build | Check a build has completed successfully |
| Job run | Check a job run has completed successfully |
Next steps
Run a template
Run templates manually or automatically.
Update a template
Update a template and resources within a project.
GitOps on Northflank
Use templates and release flows in a Git repository to trigger changes to your config and resources.
Share a template
Share templates with your team or the public.
Manage template versions on Northflank
Use the template drafts system to review, accept, or reject proposed changes to your team's Northflank templates.