Skip to main content

Split multidoc yaml formatted kubernetes descriptors to a set of single resource files

Project description

kubesplit

https://img.shields.io/pypi/v/kubesplit.svg https://circleci.com/gh/looztra/kubesplit.svg?style=svg

Split multidoc yaml formatted kubernetes descriptors to a set of single resource files

Features

  • Invalid Kubernetes resources are ignored

  • Empty resources are ignored

  • Each resource found in the input is stored in a file with a name reflecting the name of the resource and its _kubernetes_ kind

  • Cluster-wide resources (namespaces, clusterroles, clusterrolebindings) are stored in the root directory of the output, namespaced resources are stored in a subdirectory named like the namespace

  • By default, resources are prefixed

  • By default, quotes are preserved, use –no-quotes-preserved to disable quotes unless needed (for boolean and numbers if they were provided in the input as for the moment Kubesplit is not aware of the fact that only kubernetes annotations and environment variables require string)

  • By default, dash elements in list are pushed inwards, you can disable this behaviour with the -d/–no-dash-inwards option

  • Comments are preserved

  • The output directory will be created if it doesn’t exist (if the user running the command as sufficient rights)

  • You can clean (delete files and directories existing before running kubesplit) the output directory with the -c/–clean-output-dir (use at your own risks)

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

History

0.1.0 (2019-06-16)

  • First release on PyPI.

0.2.0 (2019-06-16)

  • Fix yaml formatting application

  • Allow unprefixed resource files

  • Support for ReplicaSets order

0.3.0 (2020-05-17)

  • refactoruse the newly available yamkix module and rely on its configuration and writer helpers that make all the yaml writing options work as expected (some of them were not working)
    • now kubesplit can also deal with comments!

  • fix #5 (deal with Lists)

  • chore(CI): introduce some integration tests

0.3.1 (2020-05-17)

  • dummy release so that the history is updated on PyPi

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

kubesplit-0.3.1.tar.gz (15.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kubesplit-0.3.1-py2.py3-none-any.whl (11.0 kB view details)

Uploaded Python 2Python 3

File details

Details for the file kubesplit-0.3.1.tar.gz.

File metadata

  • Download URL: kubesplit-0.3.1.tar.gz
  • Upload date:
  • Size: 15.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.7.7

File hashes

Hashes for kubesplit-0.3.1.tar.gz
Algorithm Hash digest
SHA256 1da46f52b337226b3fe86d69b8e0ab407e535e63598d7c2ed9add2fcb962f506
MD5 beac2ada73b3887c611a2be50f1b2fae
BLAKE2b-256 da60f3967ec58afbf56aefe6d534f6ffa72acfffd67848a0cbfc300697ba507d

See more details on using hashes here.

File details

Details for the file kubesplit-0.3.1-py2.py3-none-any.whl.

File metadata

  • Download URL: kubesplit-0.3.1-py2.py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.7.7

File hashes

Hashes for kubesplit-0.3.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 c5af557a00e7413c0eb16e04b7f27c175250624faf99430345cbe79d5e37cc0f
MD5 164ea18a0e0b0533a44d9ca7ce342bab
BLAKE2b-256 0bf66d2af9f310bd819fcdb5bc23327b02f53fc94461e68308fde12ab4b3dee4

See more details on using hashes here.

Supported by

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