Skip to content

Commit

Permalink
3 function slack categorize (#9)
Browse files Browse the repository at this point in the history
* Makefile in lieu of docker-compose.yml
* Makefile and poetry
* Update README.md with Make commands
* entrypoint.sh
* returns Slack user, channel and test of message for message_hello
* rename message_counts inside increase_counter for clarity
* Updating pydantic (1.10.8 -> 1.10.9)
* Updating urllib3 (2.0.2 -> 2.0.3)
* add event handler back so random text doesn't crash it
* path to csv is from poetry root (scm-poetry)
* pycharm settings
* use pandas EmptyDataError
* use message_counts_df instead of message_counts increase_counter function
* UI cleanup
---------

Co-authored-by: John Dutchover <[email protected]>
  • Loading branch information
Zaubeerer and johndutchover authored Jun 8, 2023
1 parent 7a40848 commit 73b76d2
Show file tree
Hide file tree
Showing 19 changed files with 3,221 additions and 269 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -415,3 +415,4 @@ $RECYCLE.BIN/
*.lnk

# End of https://www.toptal.com/developers/gitignore/api/linux,macos,python,pycharm,windows,visualstudiocode,vim,git
*.csv

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 22 additions & 0 deletions .idea/runConfigurations/streamlit_run.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions .idea/short-circuit-me.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 35 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Define dependencies
DEPENDENCY_1 = scm-poetry/frontend
DEPENDENCY_2 = scm-poetry/backend

# Build the dependencies
$(DEPENDENCY_1):
# Build command for dependency 1
docker build -t frontend scm-poetry/frontend

$(DEPENDENCY_2):
# Build command for dependency 2
docker build -t backend scm-poetry/backend

# Build the application
build: $(DEPENDENCY_1) $(DEPENDENCY_2)
# Build command for the main application
docker build -t frontend scm-poetry/frontend
docker build -t backend scm-poetry/backend

# Run the application
run:
docker run --name frontend -d -p 8501:8501 frontend:frontend
docker run --name backend -d backend:backend
# docker run --name backend -d -p 3000:3000 backend:backend
# Add more lines for additional subdirectories if needed

# Stop the application
stop:
docker stop frontend
docker stop backend
# Add more lines for additional subdirectories if needed

# Clean up Docker artifacts
clean:
docker system prune -f
23 changes: 18 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,25 @@
# short-circuit-me

## A _Notification_ API for Slack
## Notification broker for Slack

### api.slack.com
### Makefile
- Build containers
- `make build`

#### Bolt for Python
- Run containers
- `make run`

- Stop containers
- `make stop`

- Cleanup images
- `make clean`

#### api.slack.com

##### Bolt for Python

[Package slack_bolt](https://slack.dev/bolt-python/api-docs/slack_bolt/)

Package slack_bolt
<https://slack.dev/bolt-python/api-docs/slack_bolt/>

[![Pylint](https://github.com/johndutchover/short-circuit-me/actions/workflows/pylint.yml/badge.svg)](https://github.com/johndutchover/short-circuit-me/actions/workflows/pylint.yml)
18 changes: 0 additions & 18 deletions docker-compose.yml

This file was deleted.

2 changes: 1 addition & 1 deletion scm-poetry/backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM python:3.10.11-slim
RUN mkdir /bolt
WORKDIR /bolt
COPY .env /bolt
COPY pyproject.toml /bolt
COPY pyproject.toml /bolt/
COPY slackbolt_app.py /bolt

ENV PYTHONPATH=${PYTHONPATH}:${PWD}
Expand Down
Loading

0 comments on commit 73b76d2

Please sign in to comment.