|
|
|
@ -2,71 +2,85 @@
|
|
|
|
|
|
|
|
|
|
Search and get alerts for items across the most popular auction sites.
|
|
|
|
|
|
|
|
|
|
Built with microservice architecture, for learning purposes
|
|
|
|
|
Built with microservice architecture and various fancy tools for learning purposes
|
|
|
|
|
|
|
|
|
|
### Links
|
|
|
|
|
|
|
|
|
|
- [Keybase Team Chat](keybase://team/barretthousen)
|
|
|
|
|
- [Source](https://git.vdhsn.com/Barretthousen/barretthousen)
|
|
|
|
|
- [Auction terms glossary](https://auctionsneapolitan.com/Auction-Terms-Glossary.html)
|
|
|
|
|
- [User's Site](https://barretthousen.com)
|
|
|
|
|
- [Admin Panel](https://admin.barretthousen.com)
|
|
|
|
|
- [(Staging) User's Site](https://beta.barretthousen.com)
|
|
|
|
|
- [(Staging) Admin Panel](https://beta.admin.barretthousen.com)
|
|
|
|
|
|
|
|
|
|
## Technology
|
|
|
|
|
|
|
|
|
|
### Goals
|
|
|
|
|
|
|
|
|
|
1. Ability to search upcoming and live auctions across major auction sites
|
|
|
|
|
2. Get an email digest of upcoming auctions for the week
|
|
|
|
|
|
|
|
|
|
Future goals
|
|
|
|
|
|
|
|
|
|
1. Get email alerts when these auctions are about to go live
|
|
|
|
|
2. Specify search criteria for email alerts
|
|
|
|
|
This project is for fun and learning so there are a lot of tools at play:
|
|
|
|
|
|
|
|
|
|
Infra
|
|
|
|
|
- [Tilt](): local development env orchestration
|
|
|
|
|
- [Ctlptl](): Automate local kubernetes clusters for local dev
|
|
|
|
|
- [Docker]()
|
|
|
|
|
- [Postgres]():
|
|
|
|
|
- [Traefik]():
|
|
|
|
|
- [Kustomize]():
|
|
|
|
|
- [Helm]():
|
|
|
|
|
|
|
|
|
|
## Technology
|
|
|
|
|
Backend
|
|
|
|
|
- [Go]()
|
|
|
|
|
- [goose](): Go SQL db migration tool
|
|
|
|
|
- [Sqlc](): Generate Go code to query SQL databases from migrations in a type safe way
|
|
|
|
|
- [Buf](): Nice frontend for protoc and .proto libraries
|
|
|
|
|
- [Protobufs]():
|
|
|
|
|
|
|
|
|
|
For Users
|
|
|
|
|
- [Prod](https://barretthousen.com)
|
|
|
|
|
- [Staging](https://beta.barretthousen.com)
|
|
|
|
|
Frontend
|
|
|
|
|
- [Typescript]():
|
|
|
|
|
- [SvelteKit]():
|
|
|
|
|
- [TailwindCSS]():
|
|
|
|
|
|
|
|
|
|
For Admins
|
|
|
|
|
|
|
|
|
|
- [Prod](https://beta.barretthousen.com)
|
|
|
|
|
- [Staging](https://admin.beta.barretthousen.com)
|
|
|
|
|
- [Architecture Diagram (use diagrams.net)](./doc/Barretthousen_mvp.drawio)
|
|
|
|
|
|
|
|
|
|
![Arcchitecure Diagram MVP](./doc/Barretthousen_mvp.drawio.svg)
|
|
|
|
|
|
|
|
|
|
### Services
|
|
|
|
|
|
|
|
|
|
- Web-client
|
|
|
|
|
> [Auction terms glossary](https://auctionsneapolitan.com/Auction-Terms-Glossary.html)
|
|
|
|
|
|
|
|
|
|
- [Web-client](./src/web-client/)
|
|
|
|
|
Frontend site that users access to browse upcoming auctions and subscribe for updates to their searches
|
|
|
|
|
|
|
|
|
|
- Catalog
|
|
|
|
|
API for searching upcoming auctions.
|
|
|
|
|
- [Admin-client](./src/admin-client/)
|
|
|
|
|
Enables site administrators to kicks off scrape and email jobs in Runner and Ringman, and view status on current/past jobs.
|
|
|
|
|
|
|
|
|
|
- Ringman
|
|
|
|
|
Manages email subscriptions and sending emails to users about upcoming auctions.
|
|
|
|
|
- [Catalog](./src/catalog/)
|
|
|
|
|
API for searching upcoming auctions.
|
|
|
|
|
|
|
|
|
|
- Runner
|
|
|
|
|
- [Runner](./src/runner/)
|
|
|
|
|
Scrapes sites for upcoming auctions.
|
|
|
|
|
Transforms the data into a suitable shape and stores it for use by the frontend.
|
|
|
|
|
|
|
|
|
|
- Auctioneer
|
|
|
|
|
Enables site administrators to kicks off scrape and email jobs in Runner and Ringman, and view status on current/past jobs.
|
|
|
|
|
- [Ringman](./src/ringman/)
|
|
|
|
|
Manages email subscriptions and sending emails to users about upcoming auctions.
|
|
|
|
|
|
|
|
|
|
- [Proxy-web](./src/proxy-web/)
|
|
|
|
|
Proxies JSON HTTP API requests for the web client to GRPC based services downstream
|
|
|
|
|
|
|
|
|
|
- BHDB
|
|
|
|
|
Monolithic postgres datbabase tying it all together
|
|
|
|
|
- [Proxy-admin](./src/proxy-admin/)
|
|
|
|
|
Proxies JSON HTTP API requests for the admin client to GRPC based services downstream
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### Contributing
|
|
|
|
|
## Contributing
|
|
|
|
|
|
|
|
|
|
You will need the following prereqs installed:
|
|
|
|
|
- Docker
|
|
|
|
|
- Make
|
|
|
|
|
- [asdf](https://asdf-vm.com/guide/getting-started.html)
|
|
|
|
|
|
|
|
|
|
Install `asdf` and run `hack/asdf_plugin_setup`
|
|
|
|
|
|
|
|
|
|
Everything you need is in the makefile:
|
|
|
|
|
|
|
|
|
|
```sh
|
|
|
|
|
# install asdf tools, build tooling, encryption key for sops
|
|
|
|
|
# install asdf tools, sqlc, buf
|
|
|
|
|
make setup
|
|
|
|
|
|
|
|
|
|
# generate protobufs and sql boilerplate
|
|
|
|
@ -76,8 +90,14 @@ make gen
|
|
|
|
|
make dev
|
|
|
|
|
|
|
|
|
|
# build production docker images for the backend microservices, optionally push to the respective env
|
|
|
|
|
make build-backend-image SERVICE=[catalog, runner, proxy-client, proxy-admin] [ENV=[beta, prod]]
|
|
|
|
|
make build-backend-image SERVICE=[catalog, runner, proxy-web, proxy-admin] [ENV=[beta, prod]]
|
|
|
|
|
|
|
|
|
|
# build client docker image for web frontends, optionally push to the respective env
|
|
|
|
|
make build-client-image SERVICE=[web-client] [ENV=[beta, prod]]
|
|
|
|
|
make build-client-image SERVICE=[web-client, admin-client] [ENV=[beta, prod]]
|
|
|
|
|
|
|
|
|
|
# acceptance tests
|
|
|
|
|
make acceptance-test SERVICE=[runner,catalog] ORIGIN=[beta.barretthousen.com,beta.admin.barretthousen.com]
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
For how to deploy [read me](./doc/deployment.md).
|
|
|
|
|