https://github.com/willnode/summon
NGINX module to launch any program and forward requests to it
https://github.com/willnode/summon
Last synced: 10 months ago
JSON representation
NGINX module to launch any program and forward requests to it
- Host: GitHub
- URL: https://github.com/willnode/summon
- Owner: willnode
- License: mit
- Created: 2024-03-19T04:12:27.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2024-03-21T19:19:52.000Z (almost 2 years ago)
- Last Synced: 2025-01-15T14:14:03.383Z (12 months ago)
- Language: Rust
- Homepage:
- Size: 45.9 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HTTP Summon App NGINX Module
A simple NGINX module to launch any program and forward HTTP requests to it.
Not yet ready for production. Primilarity built for [DOM Cloud](https://domcloud.co).
## Installation and Running Demo
```sh
make nginx-install
make build
make run
```
## Configuration
#### `summon_app_command ""`
**Required to activate summon module.**
Run app at ``. App must listen to `PORT` envar.
Use `proxy_pass http://localhost:$summon_port` to forward HTTP requests.
#### `summon_app_root `
Set app pwd at ``. Defaults to parent of `root`.
#### `summon_app_user `
Set app to run under user. Defaults to who owned the "file" found in args or `nobody`.
#### `summon_app_log `
Set app log to path. Defaults log to NGINX error.
#### `summon_app_idle_timeout `
Set app maximum time before getting killed because of idle traffic. Defaults 15 minutes. Set 0 to run indefinitely.
#### `summon_app_min_instance `
Spawn app at many times. Default is 1.
#### `summon_app_use_port `
Spawn app using reserved port. Will try kill any app listening to port before hand.
If `summon_app_min_instance` > 1 then app must spawn with `SO_REUSEADDR`.
If `summon_app_use_port` uses same number, test config should fail.
#### `summon_app_show_crash `
Show helpful diagnostic error information if app is crashing either at startup or in middle of request.