sceptre-openapi-substitution-hook


Namesceptre-openapi-substitution-hook JSON
Version 0.0.1 PyPI version JSON
download
home_pagehttps://github.com/nicholasphair/sceptre-openapi-substitution-hook
SummaryA Sceptre hook for resolving variables in openapi definitions.
upload_time2023-06-08 22:21:49
maintainer
docs_urlNone
authorNicholas Phair
requires_python>=3.8,<3.12
licenseApache-2.0
keywords sceptre sceptre-hook openapi
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # README

## Overview

Performs simple string substitution in openapi specifications.

Should be used until CloudFormation [natively supports this feature][1].

## Installation

Installation instructions

To install directly from PyPI
```shell
python3 -m pip install sceptre-openapi-substitution-hook
```

To install from the git repo
```shell
python3 -m pip install git+https://github.com/nicholasphair/sceptre-openapi-substitution-hook
```

## Usage/Examples

Use the hook with a [hook point](https://docs.sceptre-project.org/latest/docs/hooks.html#hook-points)

```yaml
hooks:
  <hook_point>:
    - !openapi_substituter
      openapi:
        input: <input_path>
        output: <output_path>
        substitutions:
          <key>: <val>
```

The substituer will look for strings in the form of `${<key>}` and replace them
with `<val>`.

## Example

```yaml
hooks:
  before_validate:
    - !openapi_substituter
      openapi:
        input: ../templates/openapi.yaml
        output: ../templates/openapi.yaml
        substitutions:
          foo: bar
          baz: qux
```



[1]: https://github.com/aws-cloudformation/cloudformation-coverage-roadmap/issues/1233

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/nicholasphair/sceptre-openapi-substitution-hook",
    "name": "sceptre-openapi-substitution-hook",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<3.12",
    "maintainer_email": "",
    "keywords": "sceptre,sceptre-hook,openapi",
    "author": "Nicholas Phair",
    "author_email": "np4ay@viginia.edu",
    "download_url": "https://files.pythonhosted.org/packages/c1/3d/1e7d1f09dacaa3a0cc3bdce6d78a0fb535f456fb142c8a8b26d4f57e556e/sceptre_openapi_substitution_hook-0.0.1.tar.gz",
    "platform": null,
    "description": "# README\n\n## Overview\n\nPerforms simple string substitution in openapi specifications.\n\nShould be used until CloudFormation [natively supports this feature][1].\n\n## Installation\n\nInstallation instructions\n\nTo install directly from PyPI\n```shell\npython3 -m pip install sceptre-openapi-substitution-hook\n```\n\nTo install from the git repo\n```shell\npython3 -m pip install git+https://github.com/nicholasphair/sceptre-openapi-substitution-hook\n```\n\n## Usage/Examples\n\nUse the hook with a [hook point](https://docs.sceptre-project.org/latest/docs/hooks.html#hook-points)\n\n```yaml\nhooks:\n  <hook_point>:\n    - !openapi_substituter\n      openapi:\n        input: <input_path>\n        output: <output_path>\n        substitutions:\n          <key>: <val>\n```\n\nThe substituer will look for strings in the form of `${<key>}` and replace them\nwith `<val>`.\n\n## Example\n\n```yaml\nhooks:\n  before_validate:\n    - !openapi_substituter\n      openapi:\n        input: ../templates/openapi.yaml\n        output: ../templates/openapi.yaml\n        substitutions:\n          foo: bar\n          baz: qux\n```\n\n\n\n[1]: https://github.com/aws-cloudformation/cloudformation-coverage-roadmap/issues/1233\n",
    "bugtrack_url": null,
    "license": "Apache-2.0",
    "summary": "A Sceptre hook for resolving variables in openapi definitions.",
    "version": "0.0.1",
    "project_urls": {
        "Homepage": "https://github.com/nicholasphair/sceptre-openapi-substitution-hook",
        "Repository": "https://github.com/nicholasphair/sceptre-openapi-substitution-hook"
    },
    "split_keywords": [
        "sceptre",
        "sceptre-hook",
        "openapi"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7e156d812bcba827b88ccc9de431fd45a016fcedf936642ca98679a97f20cd79",
                "md5": "4ffe2d1622f5e209d12c7821b0377847",
                "sha256": "59d1b0a7dabccc8d076a4cc469ce8defde0a49dff3cd65e9761887a0f80561e7"
            },
            "downloads": -1,
            "filename": "sceptre_openapi_substitution_hook-0.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4ffe2d1622f5e209d12c7821b0377847",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<3.12",
            "size": 11130,
            "upload_time": "2023-06-08T22:21:47",
            "upload_time_iso_8601": "2023-06-08T22:21:47.513292Z",
            "url": "https://files.pythonhosted.org/packages/7e/15/6d812bcba827b88ccc9de431fd45a016fcedf936642ca98679a97f20cd79/sceptre_openapi_substitution_hook-0.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c13d1e7d1f09dacaa3a0cc3bdce6d78a0fb535f456fb142c8a8b26d4f57e556e",
                "md5": "9b4fee72ff21ad28a87f41f8d53a14a7",
                "sha256": "205ad0ada724f78e04e3e634a3e29210cd0edd3b71531a7428fa1df0527838b5"
            },
            "downloads": -1,
            "filename": "sceptre_openapi_substitution_hook-0.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "9b4fee72ff21ad28a87f41f8d53a14a7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<3.12",
            "size": 6200,
            "upload_time": "2023-06-08T22:21:49",
            "upload_time_iso_8601": "2023-06-08T22:21:49.559751Z",
            "url": "https://files.pythonhosted.org/packages/c1/3d/1e7d1f09dacaa3a0cc3bdce6d78a0fb535f456fb142c8a8b26d4f57e556e/sceptre_openapi_substitution_hook-0.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-06-08 22:21:49",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "nicholasphair",
    "github_project": "sceptre-openapi-substitution-hook",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "tox": true,
    "lcname": "sceptre-openapi-substitution-hook"
}
        
Elapsed time: 0.08125s