Skip to content

Commit befac88

Browse files
author
Sebastian Plott
committed
changed the highlighting for all installation codeboxes and added "codehilite" to mkdocs-markdown_extensions
1 parent 768429a commit befac88

File tree

4 files changed

+38
-37
lines changed
  • docs/deploy-and-configure/installation
    • scenario-local-installation
    • scenario-redhat-enterprise-linux-7
    • scenario-single-node-cloud-installation

4 files changed

+38
-37
lines changed

docs/deploy-and-configure/installation/scenario-local-installation/index.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The code examples in this section assumes that you have POSIX-compliant shell (l
1919

2020
Open a terminal window, create a directory, copy and extract docker orchestration there.
2121

22-
```
22+
```bash
2323
# Create eccenca-corporate-memory directory in your ${HOME} and set as a
2424
# working dir.
2525

@@ -39,33 +39,33 @@ git init && git add . && git commit -m "stub"
3939

4040
Check your local environment:
4141

42-
```
42+
```bash
4343
# Run the following command to check your docker server version.
4444
# To have the current security patches, always update your docker version
4545
# to the latest one.
4646

4747
docker version | grep -i version
48-
Version: 26.1.4
48+
# Version: 26.1.4
4949

5050
# Check docker compose version, should be at least v2.*.*
5151
# update to the latest version if necessary
5252

5353
docker compose version
54-
Docker Compose version v2.29.1
54+
# Docker Compose version v2.29.1
5555

5656
# login into eccenca docker registry
5757

5858
docker login docker-registry.eccenca.com
59-
Username: yourusername
60-
Password:
61-
Login Succeeded
59+
# Username: yourusername
60+
# Password:
61+
# Login Succeeded
6262
```
6363

6464
## Installation
6565

6666
To install Corporate Memory, you need to modify your local hosts file (located in /etc/hosts), minimal configuration is as follows:
6767

68-
```
68+
```bash
6969
##
7070
# Host Database
7171
#
@@ -78,7 +78,7 @@ To install Corporate Memory, you need to modify your local hosts file (located i
7878

7979
Corporate Memory uses Ontotext GraphDB triple store as default backend. Graphdb is available as free version and does not requires a license. If you have a license for graphdb you can copy the file to the ```license```folder inside Corporate Memory's root folder.
8080

81-
```
81+
```bash
8282
cp YOUR_SE_LICENSE_FILE \
8383
${HOME}/cmem-orchestration-VERSION/licenses/graphdb-se.license
8484
# or
@@ -88,23 +88,23 @@ cp YOUR_EE_LICENSE_FILE \
8888

8989
Then change the file ```environments/config.env``` to use the correct version:
9090

91-
```
91+
```bash
9292
# Use Free, 'se' or 'ee' or adjust the mountpoint in
9393
# compose/docker-compose.store.graphdb.yaml
9494
GRAPHDB_LICENSE=se
9595
```
9696

9797
Run the command to clean workspace, pull the images, start the Corporate Memory instance and load initial data:
9898

99-
```
99+
```bash
100100
# Pulling the images will take time
101101

102102
make clean-pull-start-bootstrap
103103
```
104104

105105
You should see the output as follows:
106106

107-
```
107+
```bash
108108
make[1]: Entering directory '/home/ttelleis/cmem-dist/cmem-orchestration'
109109
The target cleans up everything and esp. REMOVES ALL YOUR DATA. Do you want to continue?
110110

@@ -160,28 +160,28 @@ After successful login, you will see Corporate Memory interface. You can now pro
160160

161161
To create a backup you have to prepare the backup folders. Make sure these folders exists and have write permissions. Run this:
162162

163-
```
163+
```bash
164164
# assuming you are currently in the the cmem-orchestration folder
165165
mkdir -p data/backups/graphs data/backups/workspace
166166
chmod 777 data/backups/graphs data/backups/workspace
167167

168168
make backup
169169
mkdir -p data/backups/keycloak
170-
Started Keycloak database backup to data/backups/keycloak/keycloak.sql ...
171-
Finished Keycloak database backup.
170+
# Started Keycloak database backup to data/backups/keycloak/keycloak.sql ...
171+
# Finished Keycloak database backup.
172172
mv data/backups/keycloak/keycloak.sql data/backups/keycloak/2024-07-26_14-15.sql
173173
ln -sf 2024-07-26_14-15.sql data/backups/keycloak/latest.sql
174174
mkdir -p data/backups/workspace
175175
docker compose run -i --rm --env "OAUTH_CLIENT_SECRET=c8c12828-000c-467b-9b6d-2d6b5e16df4a" --volume /home/ttelleis/cmem-dist/cmem-orchestration/data:/data --volume /home/ttelleis/cmem-dist/cmem-orchestration/conf/cmemc/cmemc.ini:/config/cmemc.ini cmemc -c cmem admin workspace export /data/backups/workspace/2024-07-26_14-15.zip
176-
Export workspace to /data/backups/workspace/2024-07-26_14-15.zip ... done
176+
# Export workspace to /data/backups/workspace/2024-07-26_14-15.zip ... done
177177
ln -sf 2024-07-26_14-15.zip data/backups/workspace/latest.zip
178178
mkdir -p data/backups/python-packages
179179
zip -r data/backups/python-packages/2024-07-26_14-15.zip data/python-packages
180180
adding: data/python-packages/ (stored 0%)
181181
ln -sf 2024-07-26_14-15.zip data/backups/python-packages/latest.zip
182182
mkdir -p data/backups/graphs
183183
docker compose run -i --rm --env "OAUTH_CLIENT_SECRET=c8c12828-000c-467b-9b6d-2d6b5e16df4a" --volume /home/ttelleis/cmem-dist/cmem-orchestration/data:/data --volume /home/ttelleis/cmem-dist/cmem-orchestration/conf/cmemc/cmemc.ini:/config/cmemc.ini cmemc -c cmem admin store export /data/backups/graphs/2024-07-26_14-15.zip
184-
Exporting graphs backup to /data/backups/graphs/2024-07-26_14-15.zip ... done
184+
# Exporting graphs backup to /data/backups/graphs/2024-07-26_14-15.zip ... done
185185
ln -sf 2024-07-26_14-15.zip data/backups/graphs/latest.zip
186186
zip -r data/backups/2024-07-26_14-15.zip data/backups/keycloak/2024-07-26_14-15.sql data/backups/workspace/2024-07-26_14-15.zip data/backups/graphs/2024-07-26_14-15.zip data/backups/python-packages/2024-07-26_14-15.zip
187187
adding: data/backups/keycloak/2024-07-26_14-15.sql (deflated 82%)

docs/deploy-and-configure/installation/scenario-redhat-enterprise-linux-7/index.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ This page describes a `docker compose` based orchestration running on RedHat Ent
1717

1818
Create a working directory for this scenario and inside the working directory `Vagrantfile` with the following contents:
1919

20-
```bash linenums="1"
20+
```ruby
2121
# -*- mode: ruby -*-
2222
# vi: set ft=ruby :
2323

@@ -47,7 +47,7 @@ end
4747

4848
Spin up the virtual machine:
4949

50-
```bash linenums="1"
50+
```ruby
5151
vagrant up
5252
Bringing machine 'rhel7' up with 'virtualbox' provider...
5353
==> rhel7: Importing base box 'generic/rhel7'...
@@ -86,7 +86,7 @@ Bringing machine 'rhel7' up with 'virtualbox' provider...
8686

8787
Now you can connect to the virtual machine using `~/.vagrant.d/insecure_private_key` ssh key:
8888

89-
```bash linenums="1"
89+
```bash
9090
# add vagrant ssh key to your keychain
9191
ssh-add ~/.vagrant.d/insecure_private_key
9292

@@ -99,7 +99,7 @@ ssh [email protected]
9999

100100
Install the necessary software Inside the virtual machine and download the Corporate Memory orchestration from [releases.eccenca.com](http://releases.eccenca.com/):
101101

102-
```bash linenums="1"
102+
```bash
103103
# switch to superuser
104104
sudo su
105105

@@ -135,8 +135,8 @@ chcon -Rt svirt_sandbox_file_t /opt/corporate-memory
135135

136136
Create `/opt/corporate-memory/environments/prod.env` file with the following contents:
137137

138-
```bash linenums="1"
139-
#!/bin/bash linenums="1"
138+
```bash
139+
#!/bin/bash
140140

141141
DEPLOYHOST=corporate.memory
142142
DEPLOYPROTOCOL=https
@@ -148,13 +148,13 @@ APACHE_CONFIG=default.ssl.conf
148148

149149
Login into eccenca docker registry:
150150

151-
```bash linenums="1"
151+
```bash
152152
docker login docker-registry.eccenca.com
153153
```
154154

155155
Provide a stardog license or request a trial license:
156156

157-
```bash linenums="1"
157+
```bash
158158
# check validity of your license
159159
make stardog-license-check
160160
docker run -it --rm --name stardog-license-check -v data:/data -v /opt/corporate-memory//conf/stardog/stardog-license-key.bin:/data/stardog-license-key.bin docker-registry.eccenca.com/complexible-stardog:v7.2.0-1 stardog-admin license info /data/stardog-license-key.bin
@@ -212,7 +212,7 @@ Quantity: 3
212212
213213
Finally deploy the Corporate Memory instance:
214214
215-
```bash linenums="1"
215+
```bash
216216
# create local truststore
217217
CONFIGFILE=environments/prod.env make buildTrustStore
218218

@@ -226,7 +226,7 @@ You have successfully deployed a Corporate Memory instance.
226226
227227
On your localhost where you are running VirtualBox, modify /etc/hosts file:
228228
229-
```bash linenums="1"
229+
```bash
230230
echo "10.10.10.10 corporate.memory" >> /etc/hosts
231231
```
232232

docs/deploy-and-configure/installation/scenario-single-node-cloud-installation/index.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ This page describes a docker-compose based orchestration running on a server ins
1818

1919
In this step, you install necessary software on the server and execute the following commands as root:
2020

21-
```
21+
```bash
2222
sudo apt-get update
2323

2424
# install ntp and set timezone
@@ -53,7 +53,7 @@ sudo apt-get install docker-ce docker-ce-cli containerd.io \
5353

5454
Connect to the server and navigate to the directory with the Corporate Memory docker orchestration:
5555

56-
```
56+
```bash
5757
# login to the eccenca docker registry
5858
docker login docker-registry.eccenca.com
5959

@@ -84,7 +84,7 @@ For now, you can use the provided file `config.ssl-letsencrypt.env` as a templ
8484

8585
You need to change the lines with DEPLOYHOST and LETSENCRYPT_MAIL to your actual values.
8686

87-
```
87+
```bash
8888
cd /opt/cmem-orchestration/environments
8989
cp config.ssl-letsencrypt.env prod.env
9090

@@ -94,7 +94,7 @@ vi prod.env
9494

9595
In addition that, you need to remove the default config and link it to your prod.env
9696

97-
```
97+
```bash
9898
cd /opt/cmem-orchestration/environments
9999

100100
rm config.env
@@ -105,14 +105,14 @@ To see all available configuration options refer to [Docker Orchestration confi
105105

106106
Next, request SSL certificates from [letsencrypt](https://letsencrypt.org/) service:
107107

108-
```
108+
```bash
109109
cd /opt/cmem-orchestration
110110
make letsencrypt-create
111111
```
112112

113113
Change `CMEM_BASE_URI` according to your `DEPLOYHOST`.
114114

115-
```
115+
```bash
116116
# update cmemc configuration
117117
rm conf/cmemc/cmemc.ini
118118
cat <<EOF > conf/cmemc/cmemc.ini
@@ -126,14 +126,14 @@ EOF
126126

127127
Finally deploy the Corporate Memory instance:
128128

129-
```
129+
```bash
130130
make clean-pull-start-bootstrap
131131
make tutorials-import
132132
```
133133

134134
Optional: you can install cmem as a systemd service for this use these commands as root or sudo:
135135

136-
```
136+
```bash
137137
cp /opt/cmem-orchestration/conf/systemd/cmem-orchestration.service \
138138
/etc/systemd/system
139139
systemctl enable cmem-orchestration
@@ -157,7 +157,7 @@ Do not forget to change the passwords of your deployment, especially if it is av
157157
For this, take a look at [Change Passwords and Keys](../../configuration/keycloak/change-passwords-and-keys/index.md).
158158

159159

160-
```
160+
```bash
161161
cp /opt/cmem-orchestration/conf/systemd/cmem-orchestration.service \
162162
/etc/systemd/system
163163
systemctl enable cmem-orchestration
@@ -168,7 +168,7 @@ systemctl start cmem-orchestration
168168

169169
To create a backup you have to prepare the backup folders. Make sure these folders exists and have write permissions. Run this:
170170

171-
```
171+
```bash
172172
# assuming you are currently in the the cmem-orchestration folder
173173
mkdir -p data/backups/graphs data/backups/workspace
174174
chmod 777 data/backups/graphs data/backups/workspace

mkdocs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,7 @@ markdown_extensions:
227227
- pymdownx.snippets
228228
# https://squidfunk.github.io/mkdocs-material/reference/formatting/#adding-keyboard-keys
229229
- pymdownx.keys
230+
- codehilite
230231
# https://squidfunk.github.io/mkdocs-material/setup/extensions/python-markdown-extensions/#tasklist
231232
- pymdownx.tasklist:
232233
custom_checkbox: true

0 commit comments

Comments
 (0)