From 0124bae8bb794386d6a1d7b035cfe250b8a62632 Mon Sep 17 00:00:00 2001 From: Hutao of Emberfire Date: Mon, 12 Aug 2024 20:13:19 +0800 Subject: [PATCH] Change pulling from HTTPS to SSH in documentation (#143) --- docs/docs/intro.mdx | 43 ++++++++----------------------------------- settings.xml.example | 4 ++-- 2 files changed, 10 insertions(+), 37 deletions(-) diff --git a/docs/docs/intro.mdx b/docs/docs/intro.mdx index c889f4d6..5921ae48 100644 --- a/docs/docs/intro.mdx +++ b/docs/docs/intro.mdx @@ -35,7 +35,7 @@ Instantiating the Template Please visit [Astraios GitHub] and either -1. clone the repo with `git clone https://github.com/paion-data/astraios.git`, or +1. clone the repo with `git clone git@github.com:paion-data/astraios.git`, or 2. make it a template instantiation with our own webservice name by doing the following: ![Error loading instantiation-1.png](./img/instantiation-1.png) @@ -85,42 +85,13 @@ In the end, run `mvn clean install` to install our model From this point on, we assume [this example data model][astraios-data-models-example] is used ```bash -git clone https://github.com/paion-data/astraios-data-models-example.git -cd astraios-data-models-example.git +git clone git@github.com:paion-data/astraios-data-models-example.git +cd astraios-data-models-example mvn clean install ``` ::: -Loading Data Models -------------------- - -So now we have some models, but without an API it is not very useful. Now we need to instruct our _my-webservice_ to -load [data models](#creating-models) via Maven config file, i.e. **~/.m2/settings.xml**: - -```xml - - - - - astraios-data-models - - com.paiondata - astraios-data-models-example - 1.0.0 - - - - - - astraios-data-models - - -``` - Running ------- @@ -128,14 +99,16 @@ With data models defined, can run _my-webservice_ ```bash cd my-webservice -mvn clean package +mvn clean package --settings settings.xml.example MODEL_PACKAGE_NAME=com.paiondata.astraios.data.models docker compose up --build --force-recreate ``` :::info -`com.paiondata.astraios.data.models` is the name of the model in the aforementioned -[data model project][astraios-data-models-example] +- `com.paiondata.astraios.data.models` is the name of the model in the aforementioned + [data model project][astraios-data-models-example] +- The data model is loaded via a special-purpose Maven settings file called `settings.xml.example`, which instructs + _my-webservice_ to load [data models](#creating-models). It's essentially the regular __~/.m2/settings.xml__: ::: diff --git a/settings.xml.example b/settings.xml.example index c9fe529a..615eb79c 100644 --- a/settings.xml.example +++ b/settings.xml.example @@ -5,7 +5,7 @@ - astraios-data-models-properties + astraios-data-models com.paiondata astraios-data-models-example @@ -15,6 +15,6 @@ - astraios-data-models-properties + astraios-data-models