# junta

> Notification System: Port Monitoring, User Authorization Monitoring, Program Execution Monitoring

Latest version **1.0.2** (published 2023-05-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install junta
pnpm add junta
yarn add junta
bun add junta
```

## Health

**Score 35/100 (D)** — status: abandoned.

Positive: esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads; no types.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2023-05-31 |
| First published | 2023-05-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=18 |
| Dependencies | 5 |
| Unpacked size | 220.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | Dimitry Ivanov |
| Maintainers | ivanoff |
| Keywords | Notification System, Monitoring, Port Monitoring, User Authorization Monitoring, Program Execution Monitoring |

## Links

- npm: https://www.npmjs.com/package/junta
- Repository: https://github.com/ivanoff/junta
- Homepage: https://github.com/ivanoff/junta#readme
- Issues: https://github.com/ivanoff/junta/issues
- npm.io page: https://npm.io/package/junta

## Dependencies (5)

- [tail](https://npm.io/package/tail.md) ^2.2.6
- [dotenv](https://npm.io/package/dotenv.md) ^16.0.3
- [nodemon](https://npm.io/package/nodemon.md) ^2.0.22
- [the-log](https://npm.io/package/the-log.md) ^3.0.1
- [@slack/web-api](https://npm.io/package/@slack/web-api.md) ^6.8.1

## Alternatives

- [update-check](https://npm.io/package/update-check.md) — 4.0M weekly downloads
- [react-native-onesignal](https://npm.io/package/react-native-onesignal.md) — 134.5K weekly downloads
- [react-redux-toastr](https://npm.io/package/react-redux-toastr.md) — 33.7K weekly downloads
- [@nocobase/plugin-notification-manager](https://npm.io/package/@nocobase/plugin-notification-manager.md) — 2.0K weekly downloads
- [react-simple-toasts](https://npm.io/package/react-simple-toasts.md) — 1.9K weekly downloads

## Recent versions

- 1.0.2 (latest) — 2023-05-31
- 1.0.1 — 2023-05-31
- 0.1.1 — 2023-05-29
- 0.0.1 — 2023-05-18

## README

![junta](./logo.png)

# junta

### Port Monitoring

The program continuously scans the server for new open ports and detects when a new port becomes accessible.

### User Authorization Monitoring

It monitors user authorization activities on the server and detects when new users are granted authorization.

### Program Execution Monitoring

The program keeps track of programs running on the server and identifies when a new program is executed.

### Notification System

When any of the above events occur, the program sends you a notification or message to alert you about the event. This can be done through various communication channels such as email, SMS, or instant messaging.

## Set-up

- clone  repository and install dependences:

```
git clone https://github.com/ivanoff/junta.git
```

```
cd junta && npm install
```

- Add processes that restart periodically to `processes_skip.js` file.

- Create and edit `.env` file. The example of `.env` is below:

```
SERVER_NAME=local

TELEGRAM_BOT_TOKEN=0000000000:AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
TELEGRAM_CHATS=000000001,000000002,000000003

SLACK_TOKEN=xoxb-00000000000-0000000000000-AAAAAAAAAAAAAAAAAAAAAAA
SLACK_CHANNELS=CAAAAAAAAAAAAA,CBBBBBBBBBBBBBB
```

`SERVER_NAME` (optional) - name of the server. This information will add to each message.

`TELEGRAM_BOT_TOKEN` (optional) - telegram messenger token. See [Telegram Bots Tutorial](https://core.telegram.org/bots/tutorial)

`TELEGRAM_CHATS` (optional) - list of chat ids to send messages seeparated by comma. See [getUpdates](https://telegram-bot-sdk.readme.io/reference/getupdates) request (result->message->chat->id)

`SLACK_TOKEN` (optional) - slack token. See [Getting a Slack token](https://api.slack.com/tutorials/tracks/getting-a-token)

`SLACK_CHANNELS` (optional) - see channel properties and add bot to this channel

## Start

```
npm start
```

You can use `screen` to start in background mode

## Example

![example](./example.png)

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