Skip to main content

The Zabel Fabric

Project description



Please note that this library is not feature-complete yet.

This is part of the Zabel platform. The zabel-fabric package defines fabrics.

A fabric is what host a Zabel platform. A given fabric can host more than one Zabel platform, and it can also host other applications.

A fabric provides foundations for the applications and platforms it hosts to build upon. Those foundations include isolation, access control, secret management, as well as deployments, persistence, and discovery services.

Zabel's fabrics are not the first attempt to offer such foundations for applications. They will not be the last either.

What fabrics do is that they (try to) provide a (very) small, coherent subset of what Kubernetes clusters offer.

An application that can be deployed on a fabric can be deployed as-is on a Kubernetes cluster, if the images it uses are converted to proper containers and they preserve encapsulation.

Images, in Zabel, are plain classes with a constructor matching a known signature and a run method, so they can easily be converted to containers.

It does not mean any Python application can be automagically converted to a cloud-native application, and it of course does not imply that you can deploy your existing Kubernetes applications on a Zabel fabric.

What it means is that if your Python application has been designed to work on a Zabel fabric, it can be deployed on a full-fledged Kubernetes cluster, should the need arise.

What it also means is that you can use existing tools (such as kubectl or your favorite editor extension) to explore or change the state of a running fabric or to deploy new resources.


Here is a simple Hello World example.

Assuming the following class in a file:

import os
from time import sleep

from zabel.commons.interfaces import Image

class HelloWorld(Image):
    def __init__(self): = os.environ.get('NAME', 'World')

    def run(self):
        print(f'hello {}')
        print('good bye')

And the following pod.yaml manifest:

apiVersion: v1
kind: Pod
  name: hello
  restartPolicy: Never
  - name: Hello
    image: hello/HelloWorld
      - name: NAME
        value: 'Alice'

We can deploy it as follow:

kubectl apply -f pod.yaml

On your Zabel fabric console, the following should be displayed:

hello Alice
good bye


The following resources are available, at least partially, on fabrics:

  • v1/Events
  • v1/Namespace
  • v1/Pod
  • v1/Secret
  • v1/Service
  • v1/ServiceAccount
  • v1.apps/Deployment


Copyright (c) 2019-2020 Martin Lafaix ( and others

This program and the accompanying materials are made
available under the terms of the Eclipse Public License 2.0
which is available at

SPDX-License-Identifier: EPL-2.0

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Built Distribution

zabel_fabric-0.16.1-py3-none-any.whl (29.4 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page