https://github.com/edosrecki/oopsiee-server
An HTTP API service that simplifies daily operations and on-call duty by letting you run repeated and cumbersome tasks in no time!
https://github.com/edosrecki/oopsiee-server
cli devops on-call operations
Last synced: 3 months ago
JSON representation
An HTTP API service that simplifies daily operations and on-call duty by letting you run repeated and cumbersome tasks in no time!
- Host: GitHub
- URL: https://github.com/edosrecki/oopsiee-server
- Owner: edosrecki
- Created: 2019-09-27T13:14:07.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T11:33:11.000Z (over 2 years ago)
- Last Synced: 2024-12-22T18:39:10.661Z (6 months ago)
- Topics: cli, devops, on-call, operations
- Language: TypeScript
- Homepage: https://oopsiee.herokuapp.com/
- Size: 1.45 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 44
-
Metadata Files:
- Readme: README.adoc
Awesome Lists containing this project
README
:toc: macro
:toc-title:
:toclevels: 10= oopsiee-server
image:https://img.shields.io/github/package-json/v/edosrecki/oopsiee-server/release?color=blue&label=oopsiee-server["oOPSiee Server Version", link="https://oopsiee.herokuapp.com"]
image:https://img.shields.io/github/workflow/status/edosrecki/oopsiee-server/Continuous Integration["Build Status", link="https://github.com/edosrecki/oopsiee-server/actions"]
image:https://img.shields.io/codecov/c/github/edosrecki/oopsiee-server["Code Coverage", link="https://codecov.io/gh/edosrecki/oopsiee-server"]
image:https://img.shields.io/david/edosrecki/oopsiee-server["Dependencies Status"]An HTTP API service that simplifies **daily operations** and **on-call** duty by letting you run repeated and cumbersome
tasks in no time!Can be accessed with link:https://github.com/edosrecki/oopsiee-cli[**oOPSiee CLI**] tool, Postman, Paw, httpie, or any
other client of your choosing which speaks HTTP.* Supports **synchronous** commands
* Supports **asynchronous** jobs
* Easily **extensible**
* One command **startup**
* Ready for **Docker**
* Uses **private/public key** authentication
* Written in **TypeScript**
* 100% **test** coverage
* Has proper **dependency injection**
* Semi-automatic **dependency updates** with Dependabot
* Contains **examples**---
toc::[]
== Procedures
Each oOPSiee CLI command must have a corresponding procedure in
`oopsiee-server`. CLI command is mapped to a procedure via config
file. oOPSiee CLI tool simply reads the config file to know which
procedure to call. Procedures are called through HTTP API.=== Adding a new procedure
See example:* Procedure implementation: link:src/procedures/example[`src/procedures/example`]
* Command definition: link:src/commands/commands.yml[`src/commands/commands.yml`]== Authentication
oOPSiee CLI uses your private key to sign a JWT token containing your username,
and sends it over to oopsiee-server in the `Authorization` header. To use the CLI
add your public key to the server.=== Adding your public key
Add your public key in `PEM` format to link:keys/[`keys/`] directory.
File name must only contain your username without any file extensions.**Hint**: To convert your RSA public key to `PEM` format, run:
`ssh-keygen -f id_rsa.pub -m 'PEM' -e > `== Run
=== Development mode
==== Docker
```shell
make up
make down
make restart
```**Note**: Containers will reload automatically on code changes. However, if changes
were made to `package.json`, it is necessary to run `make restart`.==== Manual
```shell
nvm use
npm install# Start Redis manually
npm run start:job-processor:dev
npm run start:web:dev
```=== Production mode
==== Docker
```shell
make prod-up
make prod-down
make prod-restart
```==== Manual
```shell
nvm use
npm install
npm run clean
npm run build# Start Redis manually
npm run start:job-processor:prod
npm run start:web:prod
```== Test
```shell
npm test
npm run test:watch
```== Deploy
To deploy a new version of `oopsiee-server`, merge `master` branch into `release` branch.
New version will automatically get released by CI system.