https://github.com/codefeathers/up-serve
A cli tool to quickly create and manage nginx server blocks.
https://github.com/codefeathers/up-serve
automation configuration javascript nginx server up-serve
Last synced: 6 months ago
JSON representation
A cli tool to quickly create and manage nginx server blocks.
- Host: GitHub
- URL: https://github.com/codefeathers/up-serve
- Owner: codefeathers
- License: mit
- Created: 2017-10-28T07:42:35.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-10-07T11:02:22.000Z (about 7 years ago)
- Last Synced: 2025-05-19T03:12:37.163Z (7 months ago)
- Topics: automation, configuration, javascript, nginx, server, up-serve
- Language: JavaScript
- Homepage: https://up.js.org
- Size: 2.43 MB
- Stars: 18
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: Contributing.MD
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README

quick nginx server blocks in one command
# up

> Current version: `up v.0.3.1 (Alpha)`
> Notes: `up` is now in Alpha! 🎉 [(Changelog)](/docs/Changelog.md)\
> ⚠️ `up` is pretty useable so far. If you're testing `up` on a development server, do give us feedback.
**`up`** is a command line application that creates nginx server blocks quickly with a single command.
## Installation
`up` currently supports nginx mainline and nginx stable on Linux based distros. Support for more distros will come soon. Add an issue to bump this process.
You will need to have [_node JS_](https://nodejs.org) and [_nginx_](https://nginx.org) installed.
Install `up` from npm:
`npm i -g up-serve`
> `up` is now available as a command.
## Basic Commands
Format: `up command [optional]`
- `up serve [outbound port]` - Create new static server at current folder.
- `up static` is deprecated from `v. 0.2.5` (see [changelog](/docs/CHANGELOG.md))
- `up proxy [outbound port]` - Create new proxy server listening at said port.
- `up list` - List currently available servers.
- `up kill ` - Kill the server for this domain.
## Examples
- `up serve example.com` will serve a static website from current folder.
- `up proxy example.com 8081` will create a reverse proxy listening at port 8081.
- `up kill example.com` will kill the server named example.com.
- `up list` will fetch a list of servers created with `up`.
## API
```JavaScript
const up = require('up-serve')
console.log(up.version()) // up v. 0.3.0
let result = up.server({ domain: "example.com", path: "path/to/project", outPort: "80" })
console.log(result) // Will log success or throw if error
let result = up.kill({ domain: "example.com", outPort: "80" })
console.log(result) // Will log success or throw if error
```
More detailed API documentation coming soon.
---
Meta
Roadmap
Contribution Guidelines
Contributors, Collaborators, and Guides