os-collect-config


Nameos-collect-config JSON
Version 14.0.1 PyPI version JSON
download
home_pagehttps://opendev.org/openstack/os-collect-config
SummaryCollect and cache metadata, run hooks on changes.
upload_time2025-07-31 15:48:49
maintainerNone
docs_urlNone
authorOpenStack
requires_python>=3.8
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ========================
Team and repository tags
========================

.. image:: https://governance.openstack.org/tc/badges/os-collect-config.svg
    :target: https://governance.openstack.org/tc/reference/tags/index.html

.. Change things from this point on

=================
os-collect-config
=================

-------------------------------------------------
Collect configuration from cloud metadata sources
-------------------------------------------------

What does it do?
================

It collects data from defined configuration sources and runs a defined
hook whenever the metadata has been changed.

.. image:: os-collect-config-and-friends.svg

[#update_svg]_

Usage
=====

You must define what sources to collect configuration data from in
*/etc/os-collect-config.conf*.

The format of this file is::

  [DEFAULT]
  command=os-refresh-config

  [cfn]
  metadata_url=http://192.0.2.99:8000/v1/
  access_key_id = ABCDEFGHIJLMNOP01234567890
  secret_access_key = 01234567890ABCDEFGHIJKLMNOP
  path = MyResource
  stack_name = my.stack

These sources will be polled and whenever any of them is changed,
*default.command* will be run. A file will be written to the cache
dir, os_config_files.json, which will be a json list of the file paths
to the current copy of each metadata source. This list will also be
set as a colon separated list in the environment variable
*OS_CONFIG_FILES* for the command that is run. So in the example
above, *os-refresh-config* would be executed with something like this
in *OS_CONFIG_FILES*::

  /var/lib/os-collect-config/ec2.json:/var/lib/os-collect-config/cfn.json

The previous version of the metadata from a source (if available) is present at $FILENAME.last.

When run without a command, the metadata sources are printed as a json document.

Quick Start
===========

Install::

  sudo pip install -U git+https://opendev.org/openstack/os-collect-config.git

Run it on an OpenStack instance with access to ec2 metadata::

  os-collect-config

That should print out a json representation of the entire ec2 metadata tree.

.. [#update_svg] Recommend using LibreOffice draw to edit os-collect-config-and-friends.odg and regenerate the svg file. Alternatively edit the svg directly, but remove the .odg file if that is done.


            

Raw data

            {
    "_id": null,
    "home_page": "https://opendev.org/openstack/os-collect-config",
    "name": "os-collect-config",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": "OpenStack",
    "author_email": "openstack-discuss@lists.openstack.org",
    "download_url": "https://files.pythonhosted.org/packages/d7/f3/bf7ca244b38e95e46aa50cb4fdeed75e2d797087f21bb8a5ba9af22defe8/os_collect_config-14.0.1.tar.gz",
    "platform": null,
    "description": "========================\nTeam and repository tags\n========================\n\n.. image:: https://governance.openstack.org/tc/badges/os-collect-config.svg\n    :target: https://governance.openstack.org/tc/reference/tags/index.html\n\n.. Change things from this point on\n\n=================\nos-collect-config\n=================\n\n-------------------------------------------------\nCollect configuration from cloud metadata sources\n-------------------------------------------------\n\nWhat does it do?\n================\n\nIt collects data from defined configuration sources and runs a defined\nhook whenever the metadata has been changed.\n\n.. image:: os-collect-config-and-friends.svg\n\n[#update_svg]_\n\nUsage\n=====\n\nYou must define what sources to collect configuration data from in\n*/etc/os-collect-config.conf*.\n\nThe format of this file is::\n\n  [DEFAULT]\n  command=os-refresh-config\n\n  [cfn]\n  metadata_url=http://192.0.2.99:8000/v1/\n  access_key_id = ABCDEFGHIJLMNOP01234567890\n  secret_access_key = 01234567890ABCDEFGHIJKLMNOP\n  path = MyResource\n  stack_name = my.stack\n\nThese sources will be polled and whenever any of them is changed,\n*default.command* will be run. A file will be written to the cache\ndir, os_config_files.json, which will be a json list of the file paths\nto the current copy of each metadata source. This list will also be\nset as a colon separated list in the environment variable\n*OS_CONFIG_FILES* for the command that is run. So in the example\nabove, *os-refresh-config* would be executed with something like this\nin *OS_CONFIG_FILES*::\n\n  /var/lib/os-collect-config/ec2.json:/var/lib/os-collect-config/cfn.json\n\nThe previous version of the metadata from a source (if available) is present at $FILENAME.last.\n\nWhen run without a command, the metadata sources are printed as a json document.\n\nQuick Start\n===========\n\nInstall::\n\n  sudo pip install -U git+https://opendev.org/openstack/os-collect-config.git\n\nRun it on an OpenStack instance with access to ec2 metadata::\n\n  os-collect-config\n\nThat should print out a json representation of the entire ec2 metadata tree.\n\n.. [#update_svg] Recommend using LibreOffice draw to edit os-collect-config-and-friends.odg and regenerate the svg file. Alternatively edit the svg directly, but remove the .odg file if that is done.\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Collect and cache metadata, run hooks on changes.",
    "version": "14.0.1",
    "project_urls": {
        "Homepage": "https://opendev.org/openstack/os-collect-config"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4842502b2c3430d0e5e4844960f13427627f483ca66c400cc31203a4fe2964aa",
                "md5": "60dd348a20270435bc5dd63a04b7299f",
                "sha256": "4d7683a446d6004d181665db12162d8c9045e727bc1b0a1b7019fc61859ec0f5"
            },
            "downloads": -1,
            "filename": "os_collect_config-14.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "60dd348a20270435bc5dd63a04b7299f",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 55485,
            "upload_time": "2025-07-31T15:48:48",
            "upload_time_iso_8601": "2025-07-31T15:48:48.468009Z",
            "url": "https://files.pythonhosted.org/packages/48/42/502b2c3430d0e5e4844960f13427627f483ca66c400cc31203a4fe2964aa/os_collect_config-14.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d7f3bf7ca244b38e95e46aa50cb4fdeed75e2d797087f21bb8a5ba9af22defe8",
                "md5": "2d21e08e0c3533fcf23c15075069a0f6",
                "sha256": "f8d3d45147e5ed3a25ce94d84c005e8ac66de245b154ae52c8324ea502169b51"
            },
            "downloads": -1,
            "filename": "os_collect_config-14.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "2d21e08e0c3533fcf23c15075069a0f6",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 59943,
            "upload_time": "2025-07-31T15:48:49",
            "upload_time_iso_8601": "2025-07-31T15:48:49.586969Z",
            "url": "https://files.pythonhosted.org/packages/d7/f3/bf7ca244b38e95e46aa50cb4fdeed75e2d797087f21bb8a5ba9af22defe8/os_collect_config-14.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-31 15:48:49",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "os-collect-config"
}
        
Elapsed time: 1.66293s