Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dustin/confsed
JSON REST API stream editor.
https://github.com/dustin/confsed
Last synced: 3 days ago
JSON representation
JSON REST API stream editor.
- Host: GitHub
- URL: https://github.com/dustin/confsed
- Owner: dustin
- Created: 2013-09-30T19:33:14.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2013-11-14T18:46:10.000Z (about 11 years ago)
- Last Synced: 2024-11-11T13:05:31.251Z (about 1 month ago)
- Language: Go
- Size: 105 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
Awesome Lists containing this project
README
# rewriting REST
confsed is a tool that proxies HTTP requests to a REST API that
returns JSON, allowing rewrites of string responses.I wrote this because I'm NATting a service that self-describes, but
doesn't know how to address itself when sending clients off to
different ports.I'm using this currently with a double-natted service (couchbase
server in docker in virtualbox via vagrant) successfully.# Usage
Write a JSON rewrite rule thing:
```json
{
"original": "rewritten",
"1.2.3.4": "5.6.7.8"
}
```Then run
confsed -rewriteconf myconf.json http://origin/
Now, make all requests to the confsed server (default port is `7081`)
and the magic happens.