Skip to main content

Python library to interact with Linux kernel namespaces.

Project description

Documentation Status PyPI - Version

Python-lxns

Python library to control Linux kernel namespaces

Implemented using C extension module.

Current features implemented:

  • Linux namespaces class abstractions with automatic resource control.
    • Opening existing namespaces using PIDs.
    • Opening parent user namespaces. (usually unaccessible from /proc)
    • Switching to a namespace.
    • Unsharing namespaces either from class method or function with boolean flags.
    • Automatic file descriptor resource control using with.
    • Getting and setting the max number of namespaces.
  • Mount utilities using new file descriptor based API.
    • Create bind mounts.

Documentation

Also see examples/ folder for code examples.

Requirements

  • Python version 3.7 or higher

PyPI wheels

PyPI wheels are completely statically linked and do not depend on any library.

Available architectures: x86_64, i686, aarch64, armv7l

Compiling source package

  • Meson build system
  • Python headers
  • C compiler
  • Linux kernel headers

License

Python-lxns is licensed under Mozilla Public License Version 2.0.

Examples in examples/ folder are licensed under MIT license.

Project details


Download files

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

Source Distribution

lxns-0.1.0.tar.gz (22.2 kB view hashes)

Uploaded Source

Built Distributions

lxns-0.1.0-cp37-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (19.3 kB view hashes)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ ARMv7l

lxns-0.1.0-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (18.2 kB view hashes)

Uploaded CPython 3.7+ manylinux: glibc 2.17+ ARM64

lxns-0.1.0-cp37-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.whl (17.0 kB view hashes)

Uploaded CPython 3.7+ manylinux: glibc 2.5+ x86-64

lxns-0.1.0-cp37-abi3-manylinux_2_5_i686.manylinux1_i686.whl (18.4 kB view hashes)

Uploaded CPython 3.7+ manylinux: glibc 2.5+ i686

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page