Skip to content

Commit

Permalink
expand docs
Browse files Browse the repository at this point in the history
  • Loading branch information
lgessler committed Jun 15, 2022
1 parent 6d29843 commit 0018bad
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions docs/book.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,26 @@ This will use the config at `env/dev/resources/config.edn`.
Run `lein test`.
This will use the config at `env/test/resources/config.edn`.

== Prod Build
Run `lein uberjar`.
== Production Build

=== Build the Client
1. Clone https://github.com/gucorpling/midas-loop-ui[midas-loop-ui].
2. Examine and modify the contents of `webpack.prod.js`, specifically the https://github.com/gucorpling/midas-loop-ui/blob/2bfe96b3cc640585bf017fd02eaccdea22ab500b/webpack.prod.js#L80L87[definitions].
You must at least provide a new value for `API_ENDPOINT`, which should match the URL at which your Midas Loop backend system will be reachable.
For example, if you have a machine reachable at `http://my.university.edu`, and the Midas Loop backend system is exposed on port `3000`, your `API_ENDPOINT` should be set to `http://my.university.edu:3000/api`.
3. Install dependencies: `yarn`
4. Compile assets for production deployment: `yarn build`
5. Ensure that assets were successfully compiled at `dist/`

=== Build the Server
1. Clone https://github.com/gucorpling/midas-loop[midas-loop].
2. Move the _contents_ of the `dist/` folder you just created into `resources/public/`.
The `.js` files, etc. should be directly in the `resources/public/` folder, not in `resources/public/dist/`.
3. Compile an _uberjar_ with `lein uberjar`.
This will produce a standalone JAR ready for distribution and execution via `java -jar`.
Unless overridden, this will use the config at `env/prod/resources/config.edn`.
4. Verify that the uberjar was produced successfully by running `java -jar target/uberjar/midas-loop.jar`.
This `.jar` is the only artefact you will need to deploy.

== Building Docs
Install https://docs.asciidoctor.org/asciidoctor/latest/install/[Asciidoctor], then:
Expand Down

0 comments on commit 0018bad

Please sign in to comment.