{"_id":"@articulate/kongfig","_rev":"219-a6fea4c66fed29a7f864da821a3b6915","name":"@articulate/kongfig","description":"A tool for Kong to allow declarative configuration.","dist-tags":{"latest":"1.2.4"},"versions":{"1.2.4":{"name":"@articulate/kongfig","version":"1.2.4","description":"A tool for Kong to allow declarative configuration.","repository":{"type":"git","url":"git+https://github.com/mybuilder/kongfig.git"},"bin":{"kongfig":"./bin/kongfig"},"preferGlobal":true,"scripts":{"test":"mocha --compilers js:babel-core/register test/index.js","build":"babel src --out-dir lib","preversion":"npm test","version":"npm run build","postversion":"git push && git push --tags","publish-patch":"npm version patch && npm publish"},"author":{"name":"MyBuilder Ltd"},"license":"MIT","dependencies":{"babel-polyfill":"^6.2.0","colors":"^1.1.2","commander":"^2.9.0","isomorphic-fetch":"^2.2.0","js-yaml":"^3.4.6","minimist":"^1.2.0","object-assign":"^4.0.1","prettyjson":"^1.1.3"},"devDependencies":{"babel-core":"^6.2.1","babel-preset-es2015":"^6.1.18","babel-preset-stage-2":"^6.1.18","expect.js":"^0.3.1","mocha":"^2.3.4"},"gitHead":"aa243d5db720860166311709cecee5dbcccd8ff5","bugs":{"url":"https://github.com/mybuilder/kongfig/issues"},"homepage":"https://github.com/mybuilder/kongfig#readme","_id":"@articulate/kongfig@1.2.4","_shasum":"291e6e042dec5483e81f815be94e68ba1e8474c6","_from":".","_npmVersion":"3.7.3","_nodeVersion":"5.8.0","_npmUser":{"name":"pklingem","email":"patrick.klingemann@gmail.com"},"dist":{"shasum":"291e6e042dec5483e81f815be94e68ba1e8474c6","tarball":"https://registry.npmjs.org/@articulate/kongfig/-/kongfig-1.2.4.tgz","integrity":"sha512-NnJ3ksNpXNBgYF3peNXXRlPMTee8Xx8DuWPXpE0wQs/pfJo8o0vV8HnSFEWUlaw31UiGnle2bZFzsx6qG7zWqg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCItvyLros6tqwcO+6RMJF8nkbJYLcdT5FIrU4p93upgwIgEKlJELhPjn7+E+oS7teJ5BpKcSECNVRDIyXmKSRDbK4="}]},"maintainers":[{"name":"pklingem","email":"patrick.klingemann@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/kongfig-1.2.4.tgz_1458828815120_0.7961864187382162"},"directories":{}}},"readme":"<p align=\"center\">\n    <img src=\"logo.png\">\n</p>\n\n# Kongfig\n\nA tool for [Kong](https://getkong.org/) to allow declarative configuration.\n\nSimply define your list of api's and consumers in json and then run kongfig to ensure that your Kong is configured correctly.\n\n[![Build Status](https://travis-ci.org/mybuilder/kongfig.svg?branch=master)](https://travis-ci.org/mybuilder/kongfig)\n\n## Install\n\n### Manually\nWe recommend installing Kongfig globally\n\n```\nnpm install -g kongfig\n```\n\n### Puppet\nUse our [Puppet-Kongfig](https://forge.puppetlabs.com/mybuilder/kongfig) module to install and configure Kongfig\n\n```\npuppet module install mybuilder-kongfig\n```\n\n\n## Quick start\n\nYou can follow the [quick start](docs/guide.md) to get going in 5 minutes.\n\n\n## Apply config\n\nYou can have your config in [json](config.json.sample), [yaml](config.yml.sample), or [js](config.js.sample) if you need to support multiple environments.\n\n```\nkongfig apply --path config.yml --host localhost:8001\n```\n\n## Dump config\n\nYou can dump the existing configuration to a file or view it on a screen\n\n```\nkongfig dump --host localhost:8001 > config.yml\n```\n> You can omit the `--host` option if kong is on `localhost:8001` as this is the default value\n\nYou can specify the desired format by giving `--format` option with possible options of `json`, `yaml`, or `screen` that prints the config with colours.\n\n```bash\nkongfig dump --format screen\n```\n\n## Schema\n\nApi schema:\n\n```yaml\napis:\n  - name: mockbin # unique api name\n    attributes:\n      request_host:\n      request_path:\n      strip_request_path:\n      preserve_host:\n      upstream_url: # (required)\n```\n\nApi plugin schema:\n\n```yaml\napis:\n  - name: mockbin # unique api name\n    attributes: # ...\n    plugins:\n      - name: rate-limiting # kong plugin name\n      - attributes: # the plugin attributes\n          consumer_id:\n          config:\n\n```\n\nAll of the kong plugins should be supported if you find one that doesn't work please [add an issue](https://github.com/mybuilder/kongfig/issues/new).\n\nConsumer schema:\n\n```yaml\nconsumers:\n  - username: iphone-app\n```\n\nConsumer credential schema:\n\n```yaml\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: key-auth\n        attributes: # credential config attributes\n```\n\nConsumer ACL schema:\n\n```yaml\nconsumers:\n  - username: iphone-app\n    acls:\n      - group: acl-group-name\n```\n\n### Supported consumer credentials\n\n[Key Authentication](https://getkong.org/plugins/key-authentication/)\n\n```yaml\napis:\n  - name: mockbin # unique api name\n    attributes: # ...\n    plugins:\n      - name: key-auth\n      - attributes:\n          config:\n            key_names:\n            hide_credentials:\n\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: key-auth\n        attributes:\n          key: # required\n```\n\n[Basic Authentication](https://getkong.org/plugins/basic-authentication/)\n\n```yaml\napis:\n  - name: mockbin\n    attributes: # ...\n    plugins:\n      - name: key-auth\n      - attributes:\n          config:\n            hide_credentials:\n\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: basic-auth\n        attributes:\n          username: # required\n          password:\n```\n\n[OAuth 2.0 Authentication](https://getkong.org/plugins/oauth2-authentication/)\n\n```yaml\napis:\n  - name: mockbin\n    attributes: # ...\n    plugins:\n      - name: oauth2\n      - attributes:\n          config:\n            scopes:\n            mandatory_scope:\n            token_expiration:\n            enable_authorization_code:\n            enable_client_credentials:\n            enable_implicit_grant:\n            enable_password_grant:\n            hide_credentials:\n\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: oauth2\n        attributes:\n          name:\n          client_id: # required\n          client_secret:\n          redirect_uri: # required by kong\n```\n\n[HMAC Authentication](https://getkong.org/plugins/hmac-authentication/)\n\n```yaml\napis:\n  - name: mockbin\n    attributes: # ...\n    plugins:\n      - name: hmac-auth\n      - attributes:\n          config:\n            hide_credentials:\n            clock_skew:\n\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: hmac-auth\n        attributes:\n          username: # required\n          secret:\n```\n\n[JWT](https://getkong.org/plugins/jwt/)\n\n```yaml\napis:\n  - name: mockbin\n    attributes: # ...\n    plugins:\n      - name: jwt\n      - attributes:\n          config:\n            uri_param_names:\n            claims_to_verify:\n\nconsumers:\n  - username: iphone-app\n    credentials:\n      - name: jwt\n        attributes:\n          key: # required\n          secret:\n```\n\n### ACL Support\n\n[Kong ACL documentation](https://getkong.org/plugins/acl/)\n\n```yaml\napis:\n  - name: mockbin\n    attributes: # ...\n    plugins:\n      - name: \"acl\"\n        ensure: \"present\"\n        attributes:\n          config.whitelist: \"foo-group\"\n\nconsumers:\n  - username: \"some-username\"\n    ensure: \"present\"\n    acls:\n      - group: \"foo-group\"\n        ensure: \"present\"\n\n      - group: \"bar-group\"\n        ensure: \"present\"\n```\n\n---\nCreated by [MyBuilder](http://www.mybuilder.com/) - Check out our [blog](http://tech.mybuilder.com/) for more information and our other open-source projects.\n\n## Contributing to Kongfig\n\nWe are very grateful for any contributions you can make to the project.\n\nVisit the [Contributing](CONTRIBUTING.md) documentation for submission guidelines.\n","maintainers":[{"email":"platform@articulate.com","name":"botzo"}],"time":{"modified":"2024-04-24T15:53:00.067Z","created":"2016-03-24T14:13:37.759Z","1.2.4":"2016-03-24T14:13:37.759Z"},"homepage":"https://github.com/mybuilder/kongfig#readme","repository":{"type":"git","url":"git+https://github.com/mybuilder/kongfig.git"},"author":{"name":"MyBuilder Ltd"},"bugs":{"url":"https://github.com/mybuilder/kongfig/issues"},"license":"MIT","readmeFilename":"README.md"}