Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/aitumik/snippetbox
Snippetbox web app
https://github.com/aitumik/snippetbox
auth auth0 docker elasticsearch go golang http kibana mux-router
Last synced: 28 days ago
JSON representation
Snippetbox web app
- Host: GitHub
- URL: https://github.com/aitumik/snippetbox
- Owner: aitumik
- License: mit
- Created: 2021-11-24T15:05:51.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2022-12-19T07:52:23.000Z (about 2 years ago)
- Last Synced: 2024-11-15T12:13:04.193Z (about 2 months ago)
- Topics: auth, auth0, docker, elasticsearch, go, golang, http, kibana, mux-router
- Language: Go
- Homepage: https://aitumik-snippetbox.fly.dev/
- Size: 508 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Snippetbox
Snippetbox is a golang application for curating snippets## Docker Setup
> Note that to clone the repository you need to have git installed
```
git clone https://github.com/aitumik/snippetbox
```Make sure you have installed docker
```
cd snippetbox
```Here is the `docker-compose.yaml`
```yaml
# Application
snippetbox:
container_name: snippetbox
build:
context: .
dockerfile: Dockerfile
ports:
- "5000:5000"
depends_on:
- postgres
env_file: .env
volumes:
- ./:/snippetbox
# Database
postgres:
env_file: .env
image: "postgres"
hostname: "postgres"
ports:
- "5432:5432"
volumes:
- pgdata:/var/lib/postgresql/data
# Adminer
admner:
container_name: admner
image: dockette/adminer
restart: always
ports:
- "8085:80"
depends_on:
- postgres
# Volumes
volumes:
pgdata:
driver: local
```Build and Run
```
docker-compose up -d
```[Snippetbox](http://localhost:5000)
![Snippetbox Screenshot](/screenshots/image.png "screenshot of the homepage").
[Adminer](http://localhost:8080)
![Adminer Screenshot](/screenshots/adminer.png "screenshot of adminer").### Todo
- [ ] Oauth2 for authentication
- [ ] Redis for caching (we mostly do reads,writes are minimum)
- [ ] Kibana for analytics and visualization of data
- [ ] Setup CI/CD
- [ ] Add coverage tests### In Progress
- [ ] Add search capabilities by integrating with elasticsearch### Done ✓
- [x] Cache templates for faster rendering
- [x] Request logging middleware implemented
- [x] Panic recovery middleware
- [x] Add middlewares
- [x] Dockerize the application# Tools
* Postgres
* Elasticsearch# Coverage