Skip to content

Cloud & Ecosystem Entrypoints (GCP, Azure, Kubernetes)

Netherframe is provider-neutral—any provider on the Terraform Registry or your internal mirror works with hybrid execution, either via generated typed bindings (nf generate providers) or immediately via generic Provider and Resource constructs.

Looking for AWS? Start with the AWS Quickstart tracks. This page gives you direct starting points for Google Cloud, Microsoft Azure, and Kubernetes / Helm.


Google Cloud (GCP)

1. Generate bindings and install the GCS state backend (optional)

nf generate providers hashicorp/google --yes
uv add --editable ./providers/hashicorp/google
uv add netherframe.backends.gcp        # optional: store state in Google Cloud Storage

Authenticate using Application Default Credentials (gcloud auth application-default login or Workload Identity Federation in CI).

2. Define a GCP app

# coding: nf_autoid

from nf.core import App, Bind, BindContext, Output, Provider, Resource, Stack


def web(project: str, region: str = "europe-west1", public: bool = False) -> App:
    with App(nf_id="web", recovery_strategy="ROLLBACK") as app, Stack() as web, BindContext:
        google: Bind = Provider(nf_type="google", project=project, region=region)
        uploads: Bind = Resource(
            nf_type="google_storage_bucket",
            nf_provider=google,
            name=f"{project}-uploads",
            location="EU",
            uniform_bucket_level_access=True,
        )
        service: Bind = Resource(
            nf_type="google_cloud_run_v2_service",
            nf_provider=google,
            name="web",
            location=region,
            template=[
                {
                    "containers": [
                        {
                            "image": "us-docker.pkg.dev/cloudrun/container/hello",
                            "env": [{"name": "UPLOADS", "value": uploads.output.name}],
                        }
                    ]
                }
            ],
        )
        if public:
            Resource(
                nf_type="google_cloud_run_v2_service_iam_member",
                nf_id="public_invoker",
                nf_provider=google,
                project=project,
                location=region,
                name=service.output.name,
                role="roles/run.invoker",
                member="allUsers",
            )
        service_uri: Bind = Output(value=service.output.uri)
    return app

Register apps = ["app:web"] in pyproject.toml, then run:

nf plan --app web ++project=my-gcp-project ++public --out gcp.plan.json
nf apply --app web --plan-file gcp.plan.json

See the full typed example at examples/gcp_cloud_run.


Microsoft Azure

1. Generate bindings and install the Azure state backend (optional)

nf generate providers hashicorp/azurerm --yes
uv add --editable ./providers/hashicorp/azurerm
uv add netherframe.backends.azure      # optional: store state in Azure Blob Storage

Authenticate using Azure CLI (az login) or OIDC/service-principal credentials in CI.

2. Define an Azure app

# coding: nf_autoid

from nf.core import App, Bind, BindContext, LifecycleRules, Output, Provider, Resource, Stack


def storage(subscription_id: str, name: str, location: str = "westeurope") -> App:
    with App(nf_id="storage") as app, Stack() as store, BindContext:
        azure: Bind = Provider(nf_type="azurerm", subscription_id=subscription_id, features=[{}])
        rg: Bind = Resource(
            nf_type="azurerm_resource_group",
            nf_provider=azure,
            name=f"{name}-rg",
            location=location,
        )
        account: Bind = Resource(
            nf_type="azurerm_storage_account",
            nf_provider=azure,
            name=name,
            resource_group_name=rg.output.name,
            location=rg.output.location,
            account_tier="Standard",
            account_replication_type="LRS",
            lifecycle=LifecycleRules(prevent_destroy=True),
        )
        blob_endpoint: Bind = Output(value=account.output.primary_blob_endpoint)
    return app

Register apps = ["app:storage"] in pyproject.toml, then run:

nf plan --app storage ++subscription_id=00000000-0000-0000-0000-000000000000 ++name=acmestore123

See the full typed example at examples/azure_storage.


Kubernetes and Helm

You can manage Kubernetes and Helm resources against an existing kubeconfig—or create the cluster and configure the Kubernetes/Helm provider from its outputs in one apply using Deferred Provider Configuration.

# coding: nf_autoid

from nf.core import App, Bind, BindContext, Output, Provider, Resource, Stack


def cluster_apps(
    context: str = "kind-dev",
    teams: tuple[str, ...] = ("payments", "search"),
) -> App:
    with App(nf_id="cluster-apps") as app, Stack() as k8s, BindContext:
        kubernetes: Bind = Provider(
            nf_type="kubernetes",
            config_path="~/.kube/config",
            config_context=context,
        )
        created = {}
        for team in teams:
            ns = Resource(
                nf_type="kubernetes_namespace",
                nf_id=f"ns-{team}",
                nf_provider=kubernetes,
                metadata=[{"name": team, "labels": {"managed-by": "netherframe"}}],
            )
            created[team] = ns.output.id
        namespaces: Bind = Output(value=created)
    return app

Note for Helm: The hashicorp/helm provider locates and pulls charts during PlanResourceChange, so ensure your Helm chart repository or OCI registry is reachable and authenticated during nf plan as well as nf apply.

See examples/aws_eks_platform for creating an EKS cluster and its Kubernetes namespaces in a single deferred apply.


Any other Terraform provider

Generate typed bindings for any registry or mirror provider (Cloudflare, Datadog, GitHub, Keycloak, Snowflake, Vault, etc.) using the exact same two commands:

nf generate providers <namespace>/<type> --version <version> --yes
uv add --editable ./providers/<namespace>/<type>

Or use generic Provider(nf_type=...) and Resource(nf_type=...) directly with zero code generation. See Generate provider bindings and examples/keycloak_realm.