Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Function.yaml

The function.yaml file in the .stackit-functions subfolder in your workspace is the central manifest file for managing your function definition

In this YAML configuration file you can define the name of your function and the trigger. At the point of time only http trigger is supported.

Why a Manifest File?

  • Automation: Facilitates automated deployment, scaling, and management by the STACKIT Functions platform.
  • Portability: Allows function configurations to be defined once and applied consistently across various environments.
  • Version Control: Enables tracking of function configuration changes alongside your code.
  • Clear Definition: Provides a single source of truth for your function’s operational characteristics and dependencies.

The manifests files follow the Kubernetes Resource Definition scheme.

A valid function.yaml manifest could look like:

apiVersion: functions.stackit.cloud/v1alpha
kind: Function
metadata:
  id: 4007c2e5-73b6-11f1-88ab-964e7356151b
  name: my_test_function
  created: 2026-05-06T11:48:27Z
  annotations:
    cli.functions.stackit.cloud/trigger: http
spec: {}

As it can be seen in the snippet above, the function has an id field, which is inserted into the file upon function deploymnt. This identifier can be used as an addition to the unique function name to identify functions running on STACKIT Functions.

Function

A function consists of the function metadata object and the function specification object.

Function Metadata

  • id: The identifier of the function. Auto inserted into the function manifest once it has been successfully deployed
  • name: The unique identifier for your function. This name is used across the platform for deployment, logging, and management.
  • created: A timestamp, typically in RFC3339 format, indicating when the function’s configuration was initially created or defined.
  • labels: A set of arbitrary key-value pairs used for organizing, categorizing, and applying policies to your functions. Labels enable advanced filtering, monitoring, and operational management.
  • annotations: A set of custom annotations:
    • cli.functions.stackit.cloud/trigger: The function trigger. Currently only http is supported