# basic-http-proxy

> Basic HTTP/S proxy that simply works

Latest version **1.0.0** (published 2017-04-26) · ISC license · 0 weekly downloads

## Install

```sh
npm install basic-http-proxy
pnpm add basic-http-proxy
yarn add basic-http-proxy
bun add basic-http-proxy
```

Provides the command `proxy`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2017-04-26 |
| First published | 2017-04-26 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | compulim |
| Keywords | http, proxy, simple, basic |

## Links

- npm: https://www.npmjs.com/package/basic-http-proxy
- Repository: https://github.com/compulim/basic-http-proxy
- Homepage: https://github.com/compulim/basic-http-proxy#readme
- Issues: https://github.com/compulim/basic-http-proxy/issues
- npm.io page: https://npm.io/package/basic-http-proxy

## Dependencies (2)

- [debug](https://npm.io/package/debug.md) ^2.6.4
- [config](https://npm.io/package/config.md) ^1.25.1

## Recent versions

- 1.0.0 (latest) — 2017-04-26

## README

# basic-http-proxy

[![npm version](https://badge.fury.io/js/basic-http-proxy.svg)](https://npmjs.com/package/basic-http-proxy) [![Node.js dependencies](https://david-dm.org/compulim/basic-http-proxy.svg)](https://david-dm.org/compulim/basic-http-proxy) [![npm downloads](https://img.shields.io/npm/dm/basic-http-proxy.svg)](https://npmjs.com/package/basic-http-proxy)

Basic HTTP/S proxy that simply works. Support both HTTP and HTTPS.

## Installation

Type `npm install basic-http-proxy -g` to install.

## How to use

There are few ways to use the proxy:

* Thru command-line interface
* Thru another Node.js program
* Run it in Docker

### Running it with command-line interface

Type `proxy` and it will start listening to port `8080`.

To configure it to run under port `8888`, set environment variable `PORT` to 8888.

### Running it in Node.js

You can also run the proxy inside another Node.js program.

```js
require('basic-http-proxy')({
  port: 8080
});
```

### Running it with Docker

The proxy server can be run under Docker with [`node:alpine`](https://hub.docker.com/r/_/node/) image.

```
docker build -t proxy .
docker run -d -p 8080:8080 proxy
```

## Configuration

To configure the behavior of the proxy, you can either specify in environment variable, or thru JSON object.

| Env var name | JSON name | Description                    | Default |
| ------------ | --------- | ------------------------------ | ------- |
| `PORT`       | `port`    | Port the server will listen to | `8080`  |

## Roadmap

Check out [this list](https://github.com/compulim/basic-http-proxy/issues?q=is%3Aissue+is%3Aopen+label%3Aenhancement) for planned features.

## Contributions

Like us? [Star](https://github.com/compulim/basic-http-proxy/stargazers) us.

Found a bug? File us an [issue](https://github.com/compulim/basic-http-proxy/issues).

---
_Source: https://npm.io/package/basic-http-proxy · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
