Skip to content

Commit

Permalink
repo: update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Favo02 committed Apr 21, 2024
1 parent fe408b8 commit 25451fa
Showing 1 changed file with 29 additions and 8 deletions.
37 changes: 29 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,9 @@

**Cess Advisor** 🐪🚽 is a _stupid_ yet really _useful_ web app that helps you find a _suitable toilet_ when you are in a hurry.


## Tech stack

In short: **OCaml** 🐪 (Sihl) + **JavaScript** 🤢 (Svelte) + **PostgreSQL** 🐘 + Docker 🐳 + GitHub Actions 🚀
TL;DR: **OCaml** 🐪 (Sihl) + **JavaScript** 🤢 (Svelte) + **PostgreSQL** 🐘

> [!TIP]
> If you want to preserve your mental health, you should **NOT** write JavaScript code _(and frontends in general)_. OCaml is just better.
Expand All @@ -17,25 +16,47 @@ In short: **OCaml** 🐪 (Sihl) + **JavaScript** 🤢 (Svelte) + **PostgreSQL**

- Backend: **OCaml** 🐪
- [Sihl](https://github.com/oxidizing/sihl): OCaml framework for building web apps
- [Opium](https://github.com/rgrinberg/opium/): OCaml framework for managing HTTP requests
- [Opium](https://github.com/rgrinberg/opium/): OCaml library for managing HTTP requests
- [Caqti](https://github.com/paurkedal/ocaml-caqti): OCaml library for interacting with databases
- [Yojson](https://github.com/ocaml-community/yojson): OCaml library for JSON serialization
- [Validate](https://github.com/Axot017/validate): OCaml library for validating schemas

- Frontend: **JavaScript** ⚛️
- [Sveltekit](https://kit.svelte.dev/): JavaScript framework for frontend web development
- Frontend: **JavaScript** 🤢
- [Sveltekit](https://kit.svelte.dev/): JavaScript framework for web development
- [Tailwind CSS](https://tailwindcss.com/): CSS framework
- [DaisyUI](https://daisyui.com/): Tailwind components library

- Database: 🐘
- [PostgreSQL](https://www.postgresql.org/): relational database

- Deployment: 🐳
- [Docker](https://www.docker.com/): containerization
- [GitHub Actions](https://docs.github.com/en/actions): CI/CD
</details>

## Deployment

TL;DR: **Docker** 🐳 + **GitHub Actions** 🤖 for backend and **Cloudflare Pages** ☁️ for frontend

<details>
<summary>Detailed deployment</summary>

- Backend: **Docker** 🐳 + **GitHub Actions** 🤖
- each time a commit is pushed to the `main` branch, `deploy` GitHub action is triggered
- the action builds the Docker image and pushes it to the GitHub container registry
- the image is then pulled by my homelab server (periodically checked with Watchtower) and the container is started
- the backend is available at [https://cessadvisorapi.favo02.dev](https://cessadvisorapi.favo02.dev)

- **Frontend**: **Cloudflare Pages** ☁️
- each time a commit is pushed to the `main` branch, the Cloudflare pages integration detects the change
- the integration builds the Sveltekit app with some magic
- the frontend is available at [https://cessadvisor.pages.dev](https://cessadvisor.pages.dev) (and [https://cessadvisor.favo02.dev](https://cessadvisor.favo02.dev))

</details>

## Contributing

Each contribution is **welcome**, especially building alteranive better frontends _(if you are brave enough to write JavaScript code)_ that uses the same API.

Please follow the [conventions](#conventions) below.

## Conventions

<details>
Expand Down

0 comments on commit 25451fa

Please sign in to comment.