https://github.com/anton-johansson/callback-proxy-service
Provides an HTTP service that is useful for developers working with third party services performing some kind of webhooks.
https://github.com/anton-johansson/callback-proxy-service
callback docker-image http ldap-authentication proxy
Last synced: 18 days ago
JSON representation
Provides an HTTP service that is useful for developers working with third party services performing some kind of webhooks.
- Host: GitHub
- URL: https://github.com/anton-johansson/callback-proxy-service
- Owner: anton-johansson
- Created: 2019-02-24T15:58:26.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2022-12-09T15:11:35.000Z (over 2 years ago)
- Last Synced: 2024-12-26T23:43:49.294Z (5 months ago)
- Topics: callback, docker-image, http, ldap-authentication, proxy
- Language: JavaScript
- Homepage:
- Size: 655 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 22
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Callback proxy service
Provides an HTTP service that is useful for developers working with third party services performing some kind of webhooks. You set up a local proxy, and make it publically available over the internet and you use that public address when communicating with the third party. Those public webhook calls will smoothly land on your local development environment.
[](https://travis-ci.org/anton-johansson/callback-proxy-service)
[](https://github.com/anton-johansson/callback-proxy-service/releases)
[](https://hub.docker.com/r/antonjohansson/callback-proxy-service)
[](https://hub.docker.com/r/antonjohansson/callback-proxy-service)
[](https://hub.docker.com/r/antonjohansson/callback-proxy-service)## Running
Build and install necessary dependencies:
```shell
$ npm run build
```Start the application in development mode:
```
$ npm run dev
```This starts three processes that is watching for changes:
* `server`: Starts a HTTP server, serving the server application on port 8181, re-starting automatically if server-files are changed.
* `client / start`: Starts the client application on port 3000, re-loading the page automatically if client-files are changed.
* `client / watch-css`: Watches for changes to `*.scss` files and compiles them to `*.css`.In production mode, the server and client would be served on the same port, but in development mode we use different ones in order to get auto-reloads working properly.
## Configuration
The service is configured using a YAML file, located at `/etc/callback-proxy-service/callback-proxy-service.yaml` (but can be overridden with the environment variable `CONFIG_FILE_PATH`). Here's an example configuration file:
```yaml
http:
configPort: 8181
proxyPort: 8182
proxyEndpoint: https://callback-proxy.example.com
session:
secret: ...
ui:
suggestionPath: :8080
database:
fileName: /var/callback-proxy-service/callback-proxy-service.json
callbackHistorySize: 10
targetHistorySize: 10
auth:
static:
enabled: true
users:
- username: anton
password: secret
name: Anton Johansson
email: [email protected]
ldap:
enabled: false
domain: ...
url: ...
searchBase: ...
attributes:
username: sAMAccountName
name: cn
email: mail
log:
level: warn
```## Deploying
The service exposes two ports. One port (`8182`) for the actual proxy calls. This one needs to be exposed publically. The other port (`8181`) provides a UI for configuring proxy endpoints and should only be exposed on the local network.
### Kubernetes
There's an example Kubernetes deployment file [here](./deploy).