From 4df7d4f3ee3cf9b65258975b5546ef52f75574f8 Mon Sep 17 00:00:00 2001 From: Kostis Trantzas <ktrantzas@ece.upatras.gr> Date: Tue, 21 Jan 2025 19:11:57 +0200 Subject: [PATCH] fix for #9: - added documentation version as variable in mkdocs.yml (extra.documentation_version) --- .gitlab-ci.yml | 2 +- doc/contributing/documenting.md | 6 ++++-- doc/getting_started/deployment/docker_compose.md | 8 ++++---- doc/getting_started/deployment/kubernetes.md | 6 +++--- doc/index.md | 2 +- mkdocs.yml | 6 +++++- 6 files changed, 18 insertions(+), 12 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3ceeef28..a4f7250a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -6,7 +6,7 @@ pages: PAGES_BRANCH: gl-pages HTTPS_REMOTE: https://gitlab-ci-token:${ACCESS_TOKEN}@${CI_SERVER_HOST}/rep/${CI_PROJECT_PATH}.git before_script: - - pip install -q mkdocs-material mike mkdocs-glightbox + - pip install -q mkdocs-material mkdocs-glightbox mkdocs-markdownextradata-plugin mike - apt-get update -qq && apt-get -qq install -y git > /dev/null - git config --global --replace-all user.name $GITLAB_USER_NAME - git config --global --replace-all user.email $GITLAB_USER_EMAIL diff --git a/doc/contributing/documenting.md b/doc/contributing/documenting.md index 592de275..f5a14e5b 100644 --- a/doc/contributing/documenting.md +++ b/doc/contributing/documenting.md @@ -45,8 +45,9 @@ git checkout develop ``` bash python -m pip install mkdocs python -m pip install mkdocs-material - python -m pip install mike python -m pip install mkdocs-glightbox + python -m pip install mkdocs-markdownextradata-plugin + python -m pip install mike ``` === "Windows" @@ -58,8 +59,9 @@ git checkout develop ``` bash python -m pip install mkdocs python -m pip install mkdocs-material - python -m pip install mike python -m pip install mkdocs-glightbox + python -m pip install mkdocs-markdownextradata-plugin + python -m pip install mike ``` diff --git a/doc/getting_started/deployment/docker_compose.md b/doc/getting_started/deployment/docker_compose.md index f0c008e0..b7d917f0 100644 --- a/doc/getting_started/deployment/docker_compose.md +++ b/doc/getting_started/deployment/docker_compose.md @@ -66,7 +66,7 @@ cd openslice Download the deployment / environment preparation script ```bash -wget https://labs.etsi.org/rep/osl/code/org.etsi.osl.main/-/raw/develop/compose/deploy.sh +wget https://labs.etsi.org/rep/osl/code/org.etsi.osl.main/-/raw/{{{ documentation_version }}}/compose/deploy.sh ``` Make it executable @@ -86,10 +86,10 @@ If you run the script without selecting a branch the the main branch is going to We recommend: * main branch for the most stable experience and -* develop branch for an experience with the latest features (for develop branch installation, it is strongly advisable that you may as well follow the [develop documentation](https://osl.etsi.org/documentation/develop/deployment/)) +* develop branch for an experience with the latest features (for develop branch installation, it is strongly advisable that you may as well follow the [develop documentation](https://osl.etsi.org/documentation/develop/)) ```bash -sudo ./deploy.sh develop #[or replace main with other branch name] +sudo ./deploy.sh main #[or replace main with other branch name] ``` > **We recommend running the deploy.sh script with root permissions! In other case, some directories may not be accessible by the project building tools and hinder the smooth installation.** @@ -333,7 +333,7 @@ Example file: ```json { "TITLE": "OpenSlice by ETSI", - "PORTALVERSION":"2024Q2", + "PORTALVERSION":"{{{ documentation_version }}}", "WIKI": "https://osl.etsi.org/documentation", "BUGZILLA": "{BASEURL}/bugzilla/", "STATUS": "{BASEURL}/status/", diff --git a/doc/getting_started/deployment/kubernetes.md b/doc/getting_started/deployment/kubernetes.md index 62be5e12..a3f794ed 100644 --- a/doc/getting_started/deployment/kubernetes.md +++ b/doc/getting_started/deployment/kubernetes.md @@ -84,12 +84,12 @@ cd org.etsi.osl.main/kubernetes/helm/openslice/ ### 3. Prerequisites before deployment -Before deploying the Helm chart, ensure you have configured the necessary components as detailed in the following section, i.e. [Configure Helm Chart Services](#configure-helm-chart). By default, the `main` branch is selected for deployment. +Before deploying the Helm chart, ensure you have configured the necessary components as detailed in the following section, i.e. [Configure Helm Chart Services](#configure-helm-chart). We recommend: * main branch for the most stable experience and -* develop branch for an experience with the latest features (for develop branch installation, it is strongly advisable that you may as well follow the [develop documentation](https://osl.etsi.org/documentation/develop/deployment/)) +* develop branch for an experience with the latest features (for develop branch installation, it is strongly advisable that you may as well follow the [develop documentation](https://osl.etsi.org/documentation/develop/)) ## Configure Helm Chart @@ -346,7 +346,7 @@ E.g. You may edit "TITLE", "WIKI", etc properties with your domain title. Also c ```json { "TITLE": "OpenSlice by ETSI", - "PORTALVERSION":"2024Q2", + "PORTALVERSION":"{{{ documentation_version }}}", "WIKI": "https://osl.etsi.org/documentation", "BUGZILLA": "{BASEURL}/bugzilla/", "STATUS": "{BASEURL}/status/", diff --git a/doc/index.md b/doc/index.md index a8a7e6c7..198cf659 100644 --- a/doc/index.md +++ b/doc/index.md @@ -3,7 +3,7 @@ <img src="images/openslice_logo.png" alt="logo" width="200"/> -**Version**: 2024Q2 - SNAPSHOT ([Release Notes](https://labs.etsi.org/rep/osl/code/org.etsi.osl.main/-/releases/2024Q2)) +**Version**: {{{ documentation_version }}} ([Release Notes](https://labs.etsi.org/rep/osl/code/org.etsi.osl.main/-/releases/{{{ documentation_version }}})) The ETSI Software Development Group for OpenSlice (SDG OSL) is developing an open-source service-based Operations Support System (OSS) to deliver Network as a Service (NaaS) following specifications from major SDOs including ETSI, TM Forum and GSMA. diff --git a/mkdocs.yml b/mkdocs.yml index dea99c9b..549093c1 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -77,7 +77,10 @@ plugins: background: white shadow: true manual: false - + - markdownextradata: + jinja_options: + variable_start_string: '{{{' + variable_end_string: '}}}' # Copyright copyright: "Copyright © 2025 ETSI OSL" @@ -96,6 +99,7 @@ extra: link: https://twitter.com/OpensliceOSS version: provider: mike + documentation_version: "develop" # Page tree nav: -- GitLab