Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/falcowinkler/kudo-box
https://github.com/falcowinkler/kudo-box
Last synced: 6 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/falcowinkler/kudo-box
- Owner: falcowinkler
- License: mit
- Created: 2020-05-29T08:55:38.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-07-22T07:45:29.000Z (4 months ago)
- Last Synced: 2024-07-22T09:18:33.417Z (4 months ago)
- Language: Python
- Size: 8.1 MB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# kudo-box
A virtual kudo box.
- Team members can upload kudo card texts with a simple command
- Moderators can publish the cards in a slack channel, e.g. during agile ritualsThe functionality is powered by two independent serverless functions.
## write-kudo
This serverless function can respond to a slack command and stores a kudo text in the kudo box.
## setup
Set up a virtual env and install the dependencies:
```bash
pip install -r requirements.txt
pip install -r dev-requirements.txt
```## development
First we need some env vars;
```bash
export SLACK_SIGNING_SECRET=
export SLACK_BOT_TOKEN=
```
We can start a local database/pubsub as follows.
```bash
gcloud beta emulators datastore start &
gcloud beta emulators pubsub start &
```
Now you can run the serverless function locally with a test database.
```bash
export DATASTORE_EMULATOR_HOST=localhost:8081
export PUBSUB_EMULATOR_HOST=localhost:8432
functions-framework-python --target write_kudo --debug
```
If you want to debug locally with an actual slack request, use ngrok:
```bash
ngrok http 8080
```The `--debug` flag allows you to attach a debugger as well,
or you can create a pycharm run configuration that executes above command,
and launch it with debugger.## tests
```bash
pytest
```
## deployment