Skip to content

Commit

Permalink
chore: update docs (#131)
Browse files Browse the repository at this point in the history
  • Loading branch information
seofernando25 authored Oct 5, 2024
1 parent 6db4aa7 commit 72bb31f
Show file tree
Hide file tree
Showing 27 changed files with 783 additions and 1,207 deletions.
41 changes: 20 additions & 21 deletions devbox.json
Original file line number Diff line number Diff line change
@@ -1,24 +1,23 @@
{
"$schema": "https://raw.githubusercontent.com/jetify-com/devbox/0.12.0/.schema/devbox.schema.json",
"packages": [
"rustup@latest",
"nodejs@latest",
"inotify-tools@latest",
"starship@latest",
"protobuf@latest",
"pnpm@latest",
"pkg-config@latest",
"libiconv@latest",
"podman@latest",
"podman-compose@latest",
"libudev-zero@latest",
"sqlx-cli@latest",
"python@latest"
],
"shell": {
"init_hook": ["eval \"$(starship init $(echo $SHELL))\""],
"scripts": {
"test": ["echo \"Error: no test specified\" && exit 1"]
"$schema": "https://raw.githubusercontent.com/jetify-com/devbox/0.12.0/.schema/devbox.schema.json",
"packages": [
"rustup@latest",
"nodejs@latest",
"inotify-tools@latest",
"starship@latest",
"protobuf@latest",
"pnpm@latest",
"pkg-config@latest",
"libiconv@latest",
"docker-compose@latest",
"libudev-zero@latest",
"sqlx-cli@latest",
"python@latest"
],
"shell": {
"init_hook": ["eval \"$(starship init $(echo $SHELL))\""],
"scripts": {
"test": ["echo \"Error: no test specified\" && exit 1"]
}
}
}
}
182 changes: 49 additions & 133 deletions devbox.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,54 @@
{
"lockfile_version": "1",
"packages": {
"docker-compose@latest": {
"last_modified": "2024-09-24T01:22:05Z",
"resolved": "github:NixOS/nixpkgs/189e5f171b163feb7791a9118afa778d9a1db81f#docker-compose",
"source": "devbox-search",
"version": "2.29.7",
"systems": {
"aarch64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/5ikbi3w1jb96mhn5v9zs315cpldxl56v-docker-compose-2.29.7",
"default": true
}
],
"store_path": "/nix/store/5ikbi3w1jb96mhn5v9zs315cpldxl56v-docker-compose-2.29.7"
},
"aarch64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/b96x5nvpi4x3n90plj7ahn6vb7j4ckvp-docker-compose-2.29.7",
"default": true
}
],
"store_path": "/nix/store/b96x5nvpi4x3n90plj7ahn6vb7j4ckvp-docker-compose-2.29.7"
},
"x86_64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/cb9xmgaiall14n40xgi9wws8lp6hbgkd-docker-compose-2.29.7",
"default": true
}
],
"store_path": "/nix/store/cb9xmgaiall14n40xgi9wws8lp6hbgkd-docker-compose-2.29.7"
},
"x86_64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/8djdxjczw54c73ihiykxqygrfjwlbq81-docker-compose-2.29.7",
"default": true
}
],
"store_path": "/nix/store/8djdxjczw54c73ihiykxqygrfjwlbq81-docker-compose-2.29.7"
}
}
},
"inotify-tools@latest": {
"last_modified": "2024-07-07T07:43:47Z",
"resolved": "github:NixOS/nixpkgs/b60793b86201040d9dee019a05089a9150d08b5b#inotify-tools",
Expand Down Expand Up @@ -290,138 +338,6 @@
}
}
},
"podman-compose@latest": {
"last_modified": "2024-07-31T08:48:38Z",
"resolved": "github:NixOS/nixpkgs/c3392ad349a5227f4a3464dce87bcc5046692fce#podman-compose",
"source": "devbox-search",
"version": "1.2.0",
"systems": {
"aarch64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/0fzrg2aa1qrnq1dn8l9x9il6m126478w-podman-compose-1.2.0",
"default": true
},
{
"name": "dist",
"path": "/nix/store/s5ii2kcg851jf8xqlznjr95z8lgnzw87-podman-compose-1.2.0-dist"
}
],
"store_path": "/nix/store/0fzrg2aa1qrnq1dn8l9x9il6m126478w-podman-compose-1.2.0"
},
"aarch64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/aqdk4cdd58zzm0v4bqgcssavkdv7yfiw-podman-compose-1.2.0",
"default": true
},
{
"name": "dist",
"path": "/nix/store/phc1fj1xnxhaq0g1d96a4hjqrb2z7nv3-podman-compose-1.2.0-dist"
}
],
"store_path": "/nix/store/aqdk4cdd58zzm0v4bqgcssavkdv7yfiw-podman-compose-1.2.0"
},
"x86_64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/p1mbahwf0hhv9xf2ip74ixd2pnk372dy-podman-compose-1.2.0",
"default": true
},
{
"name": "dist",
"path": "/nix/store/w4j5zf9543jgk8ihkxli5nsvprasrwi8-podman-compose-1.2.0-dist"
}
],
"store_path": "/nix/store/p1mbahwf0hhv9xf2ip74ixd2pnk372dy-podman-compose-1.2.0"
},
"x86_64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/05sf3ff65n0svcqpbyz9v7c7nlryl534-podman-compose-1.2.0",
"default": true
},
{
"name": "dist",
"path": "/nix/store/nfp5dlf08dbg3v8ph6nxj6y4g6iaygfj-podman-compose-1.2.0-dist"
}
],
"store_path": "/nix/store/05sf3ff65n0svcqpbyz9v7c7nlryl534-podman-compose-1.2.0"
}
}
},
"podman@latest": {
"last_modified": "2024-08-14T02:42:29Z",
"resolved": "github:NixOS/nixpkgs/daf7bb95821b789db24fc1ac21f613db0c1bf2cb#podman",
"source": "devbox-search",
"version": "5.2.0",
"systems": {
"aarch64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/klxzs8lwh5ixd0rlnsmsa2119g2zc3jy-podman-5.2.0",
"default": true
},
{
"name": "man",
"path": "/nix/store/52grdfndxpszj62dbs32by0q7a7r1spf-podman-5.2.0-man",
"default": true
}
],
"store_path": "/nix/store/klxzs8lwh5ixd0rlnsmsa2119g2zc3jy-podman-5.2.0"
},
"aarch64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/s2imllbjs6mbysx5ccpply3zinddkwa9-podman-5.2.0",
"default": true
},
{
"name": "man",
"path": "/nix/store/79y83wz55qnvjk2aaw6vcax0qc41n5r2-podman-5.2.0-man",
"default": true
}
],
"store_path": "/nix/store/s2imllbjs6mbysx5ccpply3zinddkwa9-podman-5.2.0"
},
"x86_64-darwin": {
"outputs": [
{
"name": "out",
"path": "/nix/store/kxyqkm8y17w30xypyavynidmnml9scxr-podman-5.2.0",
"default": true
},
{
"name": "man",
"path": "/nix/store/gy61kgy7g8cn9ddakcph7lkms5pbxdi4-podman-5.2.0-man",
"default": true
}
],
"store_path": "/nix/store/kxyqkm8y17w30xypyavynidmnml9scxr-podman-5.2.0"
},
"x86_64-linux": {
"outputs": [
{
"name": "out",
"path": "/nix/store/rwmam4p8f25ani5qm5gy57v91caggswx-podman-5.2.0",
"default": true
},
{
"name": "man",
"path": "/nix/store/n6q63aaih420c4rv79zr2r6fjclpgxda-podman-5.2.0-man",
"default": true
}
],
"store_path": "/nix/store/rwmam4p8f25ani5qm5gy57v91caggswx-podman-5.2.0"
}
}
},
"protobuf@latest": {
"last_modified": "2024-07-31T08:48:38Z",
"resolved": "github:NixOS/nixpkgs/c3392ad349a5227f4a3464dce87bcc5046692fce#protobuf",
Expand Down Expand Up @@ -472,7 +388,7 @@
},
"python@latest": {
"last_modified": "2024-08-17T01:07:41Z",
"plugin_version": "0.0.3",
"plugin_version": "0.0.4",
"resolved": "github:NixOS/nixpkgs/cd7b95ee3725af7113bacbce91dd6549cee58ca5#python3",
"source": "devbox-search",
"version": "3.12.4",
Expand Down
7 changes: 2 additions & 5 deletions docs/.vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default defineConfig({
nav: [
{ text: "Home", link: "/" },
{ text: "Guide", link: "/guide/" },
{ text: "Hydra Provider", link: "/hydra-provider/" },
{ text: "Hydra Gateway", link: "/hydra-gateway/" },
{ text: "Web", link: "/web/" },
],

Expand All @@ -27,6 +27,7 @@ export default defineConfig({
{
items: [
{ text: "Getting Started", link: "/guide/" },
{ text: "Architecture", link: "/guide/architecture" },
{
text: "Requirements",
link: "/guide/requirements/",
Expand All @@ -43,10 +44,6 @@ export default defineConfig({
text: "Node",
link: "/guide/requirements/node",
},
{
text: "Protobuf",
link: "/guide/requirements/protobuf",
},
{
text: "Rust",
link: "/guide/requirements/rust",
Expand Down
16 changes: 16 additions & 0 deletions docs/guide/architecture.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Architecture

Here is a general overview of the architecture of the RGS project.

![RGS Architecture](/static/rgs.drawio.png)

It's main goals are to:
- Decentralize the data storage and visualization to allow for multiple ground stations to be used simultaneously
- Provide a decent and decoupled I/O interface for the rocket
- Provide a real-time data visualization interface for the rocket
- Reliably save and store data for later analysis

These goals are achieved by combining programs that:
- Do one thing and do it well
- Communicate with each other through well-defined interfaces
- Reliably handle fatal errors and edge cases
6 changes: 5 additions & 1 deletion docs/guide/hands-on/modifying-the-database.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Modifying the Database

TODO
Our schema is defined in the `db/schema/` directory. The schema is defined using the [Drizzle ORM](https://orm.drizzle.team/docs/overview) and is written in TypeScript.

Please look at their [Schema Declaration Guide](https://orm.drizzle.team/docs/sql-schema-declaration) for more information.

Make sure to read the [Database README]([../db/README.md](https://github.com/uorocketry/rgs/tree/main/db)) for how to apply your changes.
2 changes: 1 addition & 1 deletion docs/guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ The RGS infrastructure is made possible by combining the following technologies:
- [SvelteKit](https://kit.svelte.dev/docs/introduction) - A web framework that facilitates the development of visualization tools.
- [TimescaleDB](https://www.timescale.com/) - A PostgreSQL flavor that is optimized for time-series data.
- [Drizzle ORM](https://orm.drizzle.team/docs/overview) - A TypeScript-first ORM that is used to define the database schema.
- [Hasura](https://hasura.io/docs/latest/index/) - A GraphQL API that allows for easy access to real-time data.
- [Hasura](https://hasura.io/docs/latest/index/) - A GraphQL API that allows for easy access to real-time data. **Note: Hasura is being deprecated from the stack.**
- [Mavlink](https://mavlink.io/en/) - A lightweight protocol used for communication between the rocket and ground stations.
2 changes: 2 additions & 0 deletions docs/guide/requirements/development-environment.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Development Environment

If you're on linux you can skip this section.

If you're on windows you will need to install [Windows Subsystem for Linux](https://learn.microsoft.com/en-us/windows/wsl/install).

If on Mac, you will likelly want to install [Homebrew](https://brew.sh/).
Expand Down
16 changes: 5 additions & 11 deletions docs/guide/requirements/docker.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Docker

One of the most important requirements is [Docker](https://docs.docker.com/), it's how we set up the Database and GraphQL server.
One of the most important requirements is [Docker](https://docs.docker.com/), it's how we set up the Database and Grafana server.

The easiest way to install it is by downloading [Docker Desktop](https://www.docker.com/products/docker-desktop) for your operating system.

Expand All @@ -14,19 +14,11 @@ The output should look something like this:

```txt
Starting rgs_db_1 ... done
Starting rgs_migration_1 ... done
Starting rgs_hasura_1 ... done
Attaching to rgs_db_1, rgs_migration_1, rgs_hasura_1
...
Attaching to rgs_db_1, ...
```

Now check if you can open the Hasura console by going to <http://localhost:4000/console>!

If everything went right you should see something like this:

![Hasura Console](/static/hasura.png)

As a bonus, if you want to connect to the database directly on a tool like [DBeaver](https://dbeaver.io/), you can use the following credentials:
Now check if you can connect to the database directly on a tool like [DBeaver](https://dbeaver.io/), you can use the following credentials:

```txt
Host: localhost:5432
Expand All @@ -35,3 +27,5 @@ User: postgres
Password: password
Connection URL: postgres://postgres:postgres@localhost:5432/postgres
```

If everything goes right you'll be able to see some tables in the `public` schema.
4 changes: 4 additions & 0 deletions docs/guide/requirements/index.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Requirements

The ground station is built with multiple technologies, and as such, it has quite a few requirements to run.

Thankfully we use [Devbox](https://www.jetify.com/devbox) to manage most of the environment requirements.

Check their [installation guide](https://www.jetify.com/devbox/docs/installing_devbox/) for your respective platform to get started.
Loading

0 comments on commit 72bb31f

Please sign in to comment.