# deployy-mcdeployface

> A simple, stupid Node-based deploy script working with GitHub Webhooks.

Latest version **1.1.0** (published 2016-09-08) · MIT license · 0 weekly downloads

## Install

```sh
npm install deployy-mcdeployface
pnpm add deployy-mcdeployface
yarn add deployy-mcdeployface
bun add deployy-mcdeployface
```

## 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.1.0 |
| Published | 2016-09-08 |
| First published | 2016-06-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Jonathan Wilsson |
| Maintainers | jwilsson, kokarn |

## Links

- npm: https://www.npmjs.com/package/deployy-mcdeployface
- Repository: https://github.com/jwilsson/deployy-mcdeployface
- Homepage: https://github.com/jwilsson/deployy-mcdeployface#readme
- Issues: https://github.com/jwilsson/deployy-mcdeployface/issues
- npm.io page: https://npm.io/package/deployy-mcdeployface

## Dependencies (3)

- [express](https://npm.io/package/express.md) ^4.13.4
- [public-ip](https://npm.io/package/public-ip.md) ^2.0.1
- [child-process-promise](https://npm.io/package/child-process-promise.md) ^2.0.2

## Recent versions

- 1.1.0 (latest) — 2016-09-08
- 1.0.0 — 2016-06-21

## README

# Deployy McDeployface

A simple, stupid Node-based deploy script working with GitHub Webhooks.

## Setup

```bash
git clone https://github.com/jwilsson/deployy-mcdeployface.git
cd deployy-mcdeployface/
npm install
npm run build
```

## Usage example
Running via [forever](https://github.com/foreverjs/forever):

```bash
forever start /path/to/deployy-mcdeployface/dist/index.js /path/to/config.json
```

Running via [pm2](http://pm2.keymetrics.io/):

```bash
pm2 start /path/to/deployy-mcdeployface/dist/index.js -- /path/to/config.json
```

When you start you will get a list of what webhooks to add to each repo.
The URL to ping should include a name of the repo in a `target` query string, `http://example.com:1234/?target=deployy-mcdeployface` will trigger a deploy for this script.

Then, whenever a push to a GitHub repo is made, this script will be pinged and perform the steps outlined for that repo.

For example:

```json
{
    "port": 1234,
    "host": "example.com",
    "path": "/deployy-mcdeployface",
    "stopOnError": true,
    "repos": {
        "deployy-mcdeployface": {
            "path": "/local/path/to/repo",
            "commands": [
                "git pull",
                "npm install",
                "npm run build"
            ]
        }
    }
}
```

## Response codes

| Code | Meaning                                                                                         |
|------|-------------------------------------------------------------------------------------------------|
| 200  | Got a valid GitHub push event                                                                   |
| 204  | Got a valid GitHub ping event                                                                   |
| 400  | Got a request without a target parameter                                                        |
| 401  | Got an invalid message either with an unsupported GitHub event or without a GitHub event header |

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