Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/gemini-testing/ssh-tunneler

Plugin for gemini and hermione to set up ssh tunnel while running tests
https://github.com/gemini-testing/ssh-tunneler

gemini-plugin hermione-plugin

Last synced: about 2 months ago
JSON representation

Plugin for gemini and hermione to set up ssh tunnel while running tests

Awesome Lists containing this project

README

        

# ssh-tunneler [![Build Status](https://travis-ci.org/gemini-testing/ssh-tunneler.svg?branch=master)](https://travis-ci.org/gemini-testing/ssh-tunneler)

Plugin for [gemini](https://github.com/gemini-testing/gemini) and [hermione](https://github.com/gemini-testing/hermione) to set up ssh tunnel while running tests.

## Install

```bash
$ npm install ssh-tunneler
```

## Configuration

* **host** (mandatory) `String` – address of a remote host to which ssh tunnel will be established
* **ports** (mandatory) `Object` - ports range on a remote host; port will be picked randomly from this range
* **min** `Number` – min port number
* **max** `Number` - max port number
* **localport** (mandatory) `Number` - available port on a local machine
* **user** (optional) `String` - user to connect to a remote host
* **sshPort** (optional) `Number` - port which should be used to create ssh tunnel, default is `22`
* **retries** (optional) `Number` - the number of attempts to establish a tunnel, default is `5`
* **protocol** (optional) `String` - protocol which will be used in a resulting base url, default is `http`
* **enabled** (optional) `Boolean` - switch on/off the plugin; the plugin is switched on by default.
* **urlDecorator** (optional) `Function` - provides the ability to decorate a resulting base url; function accepts two arguments - 1) a current value of a base url, 2) an instance of a created ssh tunnel

## Usage

### gemini

Add the plugin to your configuration file:

```js
module.exports = {
system: {
plugins: {
'ssh-tunneler/gemini': {
// configuration
}
}
}
};
```

### hermione

Add the plugin to your configuration file:

```js
module.exports = {
plugins: {
'ssh-tunneler/hermione': {
// configuration
}
}
};
```