# aws-metrics-sender

> This is a script that listens on the metrics files and sends added metrics to AWS Cloudwatch.

Latest version **4.0.1** (published 2021-07-04) · ISC license · 0 weekly downloads

## Install

```sh
npm install aws-metrics-sender
pnpm add aws-metrics-sender
yarn add aws-metrics-sender
bun add aws-metrics-sender
```

Provides the command `aws-metrics-sender`.

## 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 | 4.0.1 |
| Published | 2021-07-04 |
| First published | 2019-05-24 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 152 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | ffeast |

## Links

- npm: https://www.npmjs.com/package/aws-metrics-sender
- Repository: https://github.com/ffeast/aws-metrics-sender
- Issues: https://github.com/ffeast/aws-metrics-sender/issues
- npm.io page: https://npm.io/package/aws-metrics-sender

## Dependencies (3)

- [tail](https://npm.io/package/tail.md) ^2.0.2
- [yargs](https://npm.io/package/yargs.md) ^13.3.2
- [aws-sdk](https://npm.io/package/aws-sdk.md) ^2.446.0

## Recent versions

- 4.0.1 (latest) — 2021-07-04
- 4.0.0 — 2021-07-04
- 3.0.0 — 2021-07-04
- 2.0.1 — 2021-06-14
- 2.0.0 — 2019-05-27
- 1.0.0 — 2019-05-24

## README

# aws-metrics-sender

This is a script that listens on the metrics files and sends added metrics to AWS Cloudwatch.

And yes, it's Windows-compatible


## Installation on Linux/Mac

1. install [nodejs](https://nodejs.org/en/download/)
2.  `npm i -g aws-metrics-sender`
3.  `aws-metrics-sender` command should be available now


## Installation on Windows
I'm not a big fan of Windows OS and it's quite likely that the following steps can be further simplified, but I ended up with the following working procedure to have aws-metrics-sender running as a windows service
1. install [nodejs](https://nodejs.org/en/download/). There's an `.msi` available so the installation is fairly straightforward
2. create a directory `C:\aws-metrics-sender` or any other directory convenient for you
3. `cd dir` where `dir` is the the directory from step 2.
4. `npm i aws-metrics-sender`
5. `npm i -g node-windows`
6. put `agent-service.js` to . ([example](https://github.com/ffeast/aws-metrics-sender/blob/master/examples/agent-service.js))
7. configure paths, aws creds etc
8. `node agent-service.js install`

If all went smoothly you'd see a new service **aws-metrics-sender** in the windows services:
![](images/services_list.png)

Here it is:  
![](images/service_box.png)

It's also recommended to configure script restarts:
![](images/recovery_screen.png)

If something goes wrong you can check out log files in the `node_modules\aws-metrics-sender\daemon` folder

To uninstall the service just run
`node agent-service.js uninstall`

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