# menuet-server

> A client-server application for serving dynamic menus - created to simulate the contribution of cyber or social media analysts in a mission.

Latest version **0.1.2** (published 2018-04-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install menuet-server
pnpm add menuet-server
yarn add menuet-server
bun add menuet-server
```

Provides the command `menuet-server`.

## Health

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

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2018-04-18 |
| First published | 2018-04-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 12 |
| Unpacked size | 3.3 MB |
| Known vulnerabilities | 0 (+28 in 2 direct dependencies) |
| Install scripts | no |
| Author | Erik Vullings |
| Maintainers | erikvullings |
| Keywords | menu, test-bed, kafka, simulation, cyber, security, social, media, analysts, game |

## Links

- npm: https://www.npmjs.com/package/menuet-server
- Repository: https://github.com/TNOCS/menuet
- Homepage: https://github.com/TNOCS/menuet#readme
- Issues: https://github.com/TNOCS/menuet/issues
- npm.io page: https://npm.io/package/menuet-server

## Dependencies (12)

- [cors](https://npm.io/package/cors.md) ^2.8.4
- [axios](https://npm.io/package/axios.md) ^0.18.0
- [express](https://npm.io/package/express.md) ^4.16.3
- [js-yaml](https://npm.io/package/js-yaml.md) ^3.11.0
- [chokidar](https://npm.io/package/chokidar.md) ^2.0.3
- [socket.io](https://npm.io/package/socket.io.md) ^2.1.0
- [@types/js-yaml](https://npm.io/package/@types/js-yaml.md) ^3.11.1
- [@types/chokidar](https://npm.io/package/@types/chokidar.md) ^1.7.5
- [materialize-css](https://npm.io/package/materialize-css.md) ^0.100.2
- [command-line-args](https://npm.io/package/command-line-args.md) ^5.0.2
- [command-line-usage](https://npm.io/package/command-line-usage.md) ^5.0.4
- [node-test-bed-adapter](https://npm.io/package/node-test-bed-adapter.md) ^0.4.0

## Recent versions

- 0.1.2 (latest) — 2018-04-18

## README

# menuet
A client-server application for serving dynamic menus - created to simulate the contribution of cyber or social media analysts in a mission.

The basic idea is as follows: when you click an item in the menu, any associated actions are executed, e.g. publish a VBS request on the Kafka bus. When a response is received, the menu is updated, and new menu entries may become available.

A default menu is displayed at start up. In the HOME menu, you can reset the server (and reload the browser).

You can also create your own menu and specify it on the command line using the -f command. For an example of a menu structure, see [menu.yaml](https://github.com/TNOCS/menuet/blob/master/packages/server/config/menu.yaml).

Updating the menu is based on events: every item you click generates an event (namely the menuId). When an external response is received, an event may be generated too (when the request SUCCEEDED), and treated similarly. Each raised event is matched with all menuItem conditions. If there is a match, the menuItem is activated and displayed.

Also, when you click a menuItem, and the `multiple` property is 1 or more, the `multiple` property is decreased by 1. When it reaches 0, the menuItem is hidden. menuItems with a `multiple` property of -1 are always visible.

## Install globally

`npm i -g menuet-server`

## Run

`menuet-server --help` to see all options, e.g.

`menuet-server -r -k localhost:3052 -s localhost:3051`

-r is only needed if you want to publish some default schema's to Apache Kafka (using the [DRIVER+ test-bed](https://github.com/DRIVER-EU/test-bed)).

## Build

`npm install`

and use

`npm run serve`

to start the dev servers.

In addition, you can fake the VBS3 responses by running the `echo-service` using `node dist/echo-service.js`. Every VBS-action-request is matched with a VBS3-action-response with a status SUCCEEDED.

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