aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authoriv-ar <i@oiee.no>2023-03-01 21:53:52 +0100
committeriv-ar <i@oiee.no>2023-03-01 21:53:52 +0100
commit1fd5d9da8aec92786012ba2f0a4495718c471367 (patch)
treeae0ab0b2d9d6e4bb27a2d894ca91ee9a0295fdff /README.md
parente0a4b1b0e48fac35e7d2b86122b9df286e10231c (diff)
downloadgreatoffice-1fd5d9da8aec92786012ba2f0a4495718c471367.tar.xz
greatoffice-1fd5d9da8aec92786012ba2f0a4495718c471367.zip
feat: Change how we enable flight mode
Diffstat (limited to 'README.md')
-rw-r--r--README.md47
1 files changed, 33 insertions, 14 deletions
diff --git a/README.md b/README.md
index 5b9ceca..c40e7f5 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,7 @@
# Greatoffice
-> This codebase and all of its source code is licensed under the GNU General Public License v3.0, see [COPYING](COPYING).
+> This codebase and all of its source code is licensed under the GNU General Public License v3.0,
+> see [COPYING](COPYING).
This repository contains all the code for greatoffice, a business management system.
@@ -13,7 +14,8 @@ The platform aims to equip it's users with tools to do
* ticketing
* task management
-Everything is WIP, but the platform is regularly updated at [https://stage.greatoffice.app](https://stage.greatoffice.app)
+Everything is WIP, but the platform is regularly updated
+at [https://stage.greatoffice.app](https://stage.greatoffice.app)
## code/api
@@ -25,24 +27,32 @@ To run it you need .NET 7 and a PostgreSQL instance.
### Database schemas
-The application schema is managed and described using entity framework core, to apply the latest migration use `dotnet ef database update`
+The application schema is managed and described using entity framework core, to apply the latest migration
+use `dotnet ef database update`
> This operation requires that you have the dotnet-ef tools installed, use `dotnet tool install -g dotnet-ef` to do so.
>
> In addition to that it requires you to have populated the required environment variables or enabled flight mode.
-Besides the application schema the api also needs a quartz database, sql scripts to create these in postgres is provided at `code/api/sql/quartz-*.sql`.
+Besides the application schema the api also needs a quartz database, sql scripts to create these in postgres is provided
+at `code/api/sql/quartz-*.sql`.
+
+I recommend using a seperate database for the quartz schema and app schema, since the app schema is managed by ef core
+and the quartz schema is not.
-I recommend using a seperate database for the quartz schema and app schema, since the app schema is managed by ef core and the quartz schema is not.
### Environment/Configuration
-The api uses Hashicorp's vault to manage it's configuration, environment variables is used to point the api in the direction of the vault json object that contains the configuration.
+The api uses Hashicorp's vault to manage it's configuration, environment variables is used to point the api in the
+direction of the vault json object that contains the configuration.
-The configuration is described by [`code/api/src/Models/Misc/AppConfiguration.cs`](./code/api/src/Models/Misc/AppConfiguration.cs).
+The configuration is described
+by [`code/api/src/Models/Misc/AppConfiguration.cs`](./code/api/src/Models/Misc/AppConfiguration.cs).
-I recommend using [user-secrets](https://docs.microsoft.com/en-us/aspnet/core/security/app-secrets) to set environment variables when developing.
+I recommend using [user-secrets](https://docs.microsoft.com/en-us/aspnet/core/security/app-secrets) to set environment
+variables when developing.
-All environment variables the api needs to function properly is specified in [`code/api/src/Models/Static/AppEnvironmentVariables.cs`](./code/api/src/Models/Static/AppEnvironmentVariables.cs).
+All environment variables the api needs to function properly is specified
+in [`code/api/src/Models/Static/AppEnvironmentVariables.cs`](./code/api/src/Models/Static/AppEnvironmentVariables.cs).
#### Minimum required configuration
@@ -53,11 +63,16 @@ The following configuration keys need valid values in order to start the api (re
* Starting with QUARTZ_DB_
* Equal to APP_CERT
-> See [`code/api/src/Models/Misc/AppConfiguration.cs`](./code/api/src/Models/Misc/AppConfiguration.cs) for expected values.
+> See [`code/api/src/Models/Misc/AppConfiguration.cs`](./code/api/src/Models/Misc/AppConfiguration.cs) for expected
+> values.
#### Flight mode
-If you need to skip the setup of vault or is unable to reach your vault instance, set FLIGHT_MODE to a positive value.
+When debugging the application you sometimes don't want to, or are not able to reach the vault for configuration values.
+In this case you can set the environment variable `FLIGHT_MODE` to something positive.
+
+This will configure the api to read configuration from a json file specified at `FLIGHT_MODE_JSON`, defaults
+to `flightmode.json`.
### Building and Developing
@@ -67,7 +82,7 @@ To build the server locally use `dotnet build` or `dotnet build -c Release` for
A helper script is available at [`code/api/build_and_push.sh`](code/api/build_and_push.sh) that handles,
-* Optionally commiting, taging and pushing latest changes to remote git source
+* Optionally commiting, tagging and pushing latest changes to remote git source
* Building a docker image
* Pushing the docker image to the default registry at dr.ivar.systems
* Bumping version number
@@ -80,8 +95,12 @@ Noteworthy information:
* The ui consists largely of components from or inspired by tailwind ui.
* When you run the frontend in dev mode, most of the available components is showcased standalone at `/book`.
-* The app uses [temporal-polyfill](https://github.com/fullcalendar/temporal) to do date and time operations, docs is [here](https://tc39.es/proposal-temporal/docs/#api-documentation) (excited to see this api implemented natively soon).
-* Svelte headless ui is used for some of the components, while the library is great it unfortunately seems to be unmaintained and therefore i forked it into `@developermuch/dev-svelte-headlessui` where i publish additions from upstream. This package can hopefully be deprecated in the future.
+* The app uses [temporal-polyfill](https://github.com/fullcalendar/temporal) to do date and time operations, docs
+ is [here](https://tc39.es/proposal-temporal/docs/#api-documentation) (excited to see this api implemented natively
+ soon).
+* Svelte headless ui is used for some of the components, while the library is great it unfortunately seems to be
+ unmaintained and therefore i forked it into `@developermuch/dev-svelte-headlessui` where i publish additions from
+ upstream. This package can hopefully be deprecated in the future.
### Environment