From 0f99d803e12b54a9d4a55e25de7c8dc6f3acab3e Mon Sep 17 00:00:00 2001 From: Simon Brown <1009874+simonbrowndotje@users.noreply.github.com> Date: Sun, 24 Nov 2024 12:38:48 +0000 Subject: [PATCH] Adds Lite building from source instructions, early access builds, etc. --- java/building.md | 29 +++++++++++ java/faq.md | 22 -------- lite/70-building.md | 51 +++++++++++++++++++ lite/71-early-access.md | 14 +++++ lite/{05-faq.md => 80-faq.md} | 2 +- ...oubleshooting.md => 81-troubleshooting.md} | 2 +- 6 files changed, 96 insertions(+), 24 deletions(-) create mode 100644 java/building.md create mode 100644 lite/70-building.md create mode 100644 lite/71-early-access.md rename lite/{05-faq.md => 80-faq.md} (98%) rename lite/{06-troubleshooting.md => 81-troubleshooting.md} (99%) diff --git a/java/building.md b/java/building.md new file mode 100644 index 0000000..b26018c --- /dev/null +++ b/java/building.md @@ -0,0 +1,29 @@ +--- +layout: default +title: Building from source +parent: Structurizr for Java +nav_order: 70 +permalink: /java/building +--- + +# Building from source + +To build from the sources (you'll need git and Java 17+ installed): + +``` +git clone https://github.com/structurizr/java.git structurizr-java +cd structurizr-java +./gradlew +``` + +This will create a number of `.jar` files. For example: + +- `structurizr-client/build/libs/structurizr-client-{version}.jar` +- `structurizr-core/build/libs/structurizr-core-{version}.jar` +- etc + +You can publish these `.jar` files to your local Maven repository with the following command: + +``` +./gradlew clean build publishToMavenLocal +``` diff --git a/java/faq.md b/java/faq.md index bb1c987..09c2177 100644 --- a/java/faq.md +++ b/java/faq.md @@ -8,28 +8,6 @@ permalink: /java/faq # Frequently asked questions -## How do I build from source? - -To build from the sources (you'll need git and Java 17+ installed): - -``` -git clone https://github.com/structurizr/java.git structurizr-java -cd structurizr-java -./gradlew -``` - -This will create a number of `.jar` files. For example: - -- structurizr-client/build/libs/structurizr-client-{version}.jar -- structurizr-core/build/libs/structurizr-core-{version}.jar -- etc - -You can publish these `.jar` files to your local Maven repository with the following command: - -``` -./gradlew clean build publishToMavenLocal -``` - ## Why is there no way to remove elements/relationships from the model? The Structurizr for Java library is designed to be append-only, and removing elements is non-trivial. diff --git a/lite/70-building.md b/lite/70-building.md new file mode 100644 index 0000000..7d9af03 --- /dev/null +++ b/lite/70-building.md @@ -0,0 +1,51 @@ +--- +layout: default +title: Building from source +parent: Structurizr Lite +nav_order: 70 +permalink: /lite/building +--- + +# Building from source + +Part of the UI is shared between the on-premises installation, cloud service, and Structurizr Lite +so you will need to additionally clone the [structurizr/ui](https://github.com/structurizr/ui) repo. + +## Build + +``` +git clone https://github.com/structurizr/lite.git structurizr-lite +git clone https://github.com/structurizr/ui.git structurizr-ui +cd structurizr-lite +./ui.sh +./gradlew clean build +``` + +If successful, you will see a file named `structurizr-lite.war` in `structurizr-onpremises/build/libs`. + +If you see an error message of the form `Could not find com.structurizr:structurizr-dsl:x.y.z`, you will need to +[build the Structurizr for Java repo from source, and publish to your local Maven repository](/java/building). + +## Run + +To run Structurizr Lite, you can then use: + +``` +java -jar build/libs/structurizr-lite.war /path/to/workspace +``` + +(replace `/path/to/workspace` with the path to the folder where your `workspace.dsl` file is) + +## Docker + +To build a Docker image: + +``` +docker build . -t mytag +``` + +And to start a Docker container from this image (replace `/path/to/dataDirectory`): + +``` +docker run -it --rm -p 8080:8080 -v /path/to/dataDirectory:/usr/local/structurizr mytag +``` \ No newline at end of file diff --git a/lite/71-early-access.md b/lite/71-early-access.md new file mode 100644 index 0000000..25a39fa --- /dev/null +++ b/lite/71-early-access.md @@ -0,0 +1,14 @@ +--- +layout: default +title: Early access features +parent: Structurizr Lite +nav_order: 71 +permalink: /lite/early-access +--- + +# Early access features + +You have two options to gain early access to new/in-progress features: + +1. Build from source - follow the instructions at [Building from source](/lite/building). +2. Use the pre-built early access builds that are available via the [Structurizr Patreon](https://patreon.com/structurizr). \ No newline at end of file diff --git a/lite/05-faq.md b/lite/80-faq.md similarity index 98% rename from lite/05-faq.md rename to lite/80-faq.md index c480f43..8a25f44 100644 --- a/lite/05-faq.md +++ b/lite/80-faq.md @@ -2,7 +2,7 @@ layout: default title: FAQ parent: Structurizr Lite -nav_order: 5 +nav_order: 80 permalink: /lite/faq --- diff --git a/lite/06-troubleshooting.md b/lite/81-troubleshooting.md similarity index 99% rename from lite/06-troubleshooting.md rename to lite/81-troubleshooting.md index 580d20b..9c9914a 100644 --- a/lite/06-troubleshooting.md +++ b/lite/81-troubleshooting.md @@ -2,7 +2,7 @@ layout: default title: Troubleshooting parent: Structurizr Lite -nav_order: 6 +nav_order: 81 permalink: /lite/troubleshooting ---