Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mgalgs/sandiegolibrebot
Serial crossposter!
https://github.com/mgalgs/sandiegolibrebot
Last synced: about 2 months ago
JSON representation
Serial crossposter!
- Host: GitHub
- URL: https://github.com/mgalgs/sandiegolibrebot
- Owner: mgalgs
- Created: 2021-10-04T22:57:05.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-07-09T06:53:11.000Z (over 2 years ago)
- Last Synced: 2024-10-15T11:27:08.423Z (3 months ago)
- Language: Python
- Size: 11.7 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Your friendly [r/SanDiegoLibre](https://reddit.com/r/SanDiegoLibre) bot.
## Local environment setup
```
git clone https://github.com/mgalgs/SanDiegoLibreBot.git
cd SanDiegoLibreBot
```And create a file named `env.sh` with the following content:
```
CLIENT_ID=
CLIENT_SECRET=
REDDIT_USERNAME=
REDDIT_PASSWORD=
```One-time virtual environment initialization:
```
python3 -m venv venv
```Then every time you want to work on the bot:
```
source enter.sh
```To run the bot against `r/SanDiegoLibreTest`:
```
python src/main.py
```To run it against `r/SanDiegoLibre`:
```
PROD=yes python src/main.py
```## Kubernetes setup
This bot is currently running on a kubernetes cluster for
high-availability.### Configuration (secrets)
First you need to make your `env.sh` into a kubernetes Secret.
```
./k8s/gen_secrets.sh sdlbot-secrets < env.sh | kubectl apply -f -
```### Deployment
```
kubectl apply -f ./k8s/deployment.yaml
```