https://github.com/deas/cljc-gcp-monitoring-to-teams-fn
🧪 GCP Monitoring to MS Teams - Clojure(Script) flavoured 🥼
https://github.com/deas/cljc-gcp-monitoring-to-teams-fn
Last synced: 2 months ago
JSON representation
🧪 GCP Monitoring to MS Teams - Clojure(Script) flavoured 🥼
- Host: GitHub
- URL: https://github.com/deas/cljc-gcp-monitoring-to-teams-fn
- Owner: deas
- License: apache-2.0
- Created: 2021-10-28T06:30:43.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2022-01-20T07:42:40.000Z (over 3 years ago)
- Last Synced: 2025-01-22T05:28:27.845Z (4 months ago)
- Language: Clojure
- Size: 38.1 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 🧪 GCP Monitoring to MS Teams - Clojure(Script) flavoured 🥼
Inspired by [gcp-monitoring-to-teams](https://github.com/Courtsite/gcp-monitoring-to-teams).

## Dev Requirements
- Java (for build, Runtime not quite yet)
- Node JS
- Terraform## Usage (Target: NodeJS)
Install dependencies
```shell
yarn install || npm install
```
Run dev process
```shell
yarn start || npm start
```
Compile
```shell
yarn run build || npm run build
```
Test
```shell
yarn run test || npm run test
```
REPL (but you most likely want to use your IDE)
```shell
yarn run repl || npm run repl
```
Run service locally
```shell
yarn run serve || npm run serve
```
Send incident to MS Teams with local service:
```shell
TEAMS_WEBHOOK=https://get.this.from.teams
curl -H 'Content-Type: application/json' -d @samples/incident.json "http://localhost:8080?auth-token=s3cr3t&teams-endpoint=${TEAMS_WEBHOOK}"
```
Sending to teams directly
```shell
curl POST -H 'Content-type:application/json' -d @samples/adaptive-incident.json $ENDPOINT
```
Deploy (terraform) - make sure to run build first
```shell
yarn run deploy || npm run deploy
```## TODO / Known Issues
- `gcp-build` does not work because there is no java on the builders
- build optimization is currently `simple` because `promesa/httpurr` appears to have an issue with `advanced` optimization
- Simplify deployment : One call on fresh source should take care of everything
- Build better tests
- Implement hot reloading for `serve`
- Implement PubSub version
- Finish cljc, do JVM host