Deploy and link demo slides

Change-Id: I7034c0f419c64a54b59d0a55778d34170df7fa08
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 7691d5f..4bc2559 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -21,7 +21,6 @@
 
   before_script:
     - source `find .. -name section_helper.sh`
-
     - start_section install_linux_packages "Installing missing Linux packages"
     - apt-get update
     - apt-get install -y libvulkan1 libu2f-udev fonts-liberation build-essential libglpk40 libcurl4-gnutls-dev libxml2-dev libsodium-dev libsecret-1-dev libfontconfig1-dev libssl-dev libxt6 libpq-dev imagemagick libnss3 libgbm-dev libxss1 libappindicator3-1 libasound2 libatk-bridge2.0-0 libgtk-3-0 libnspr4 libnss3 libgbm-dev ca-certificates curl gnupg
@@ -34,6 +33,29 @@
     - locale-gen de_DE.utf8 en_GB.utf8 en_US.utf8
     - end_section install_linux_packages
 
+
+    - start_section setup_deployment "Setup deployment"
+    - 'command -v ssh-agent >/dev/null || apt-get install openssh-client -y'
+
+  ##
+  ## Run ssh-agent (inside the build environment)
+  ##
+    - eval $(ssh-agent -s)
+
+  ##
+  ## Give the right permissions, otherwise ssh-add will refuse to add files
+  ## Add the SSH key stored in SSH_PRIVATE_KEY file type CI/CD variable to the agent store
+  ##
+    - chmod 400 "$SSH_PRIVATE_KEY"
+    - ssh-add "$SSH_PRIVATE_KEY"
+
+  ##
+  ## Create the SSH directory and give it the right permissions
+  ##
+    - mkdir -p ~/.ssh
+    - chmod 700 ~/.ssh
+    - end_section setup_deployment
+
     - start_section test_puppeteer "Testing puppeteer"
     - ./ci/screenshot https://www.google.com /tmp/google.png
     - end_section test_puppeteer
@@ -52,3 +74,5 @@
           file://`pwd`/target/ids.html#/registered-users target/users.png
           file://`pwd`/target/ids.html#/references-1 target/references.png
     - end_section render
+    - start_section deploy "Deploying slides"
+    - scp -ro StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null target/ids* cowner@klinux10:/vol/work/kupietz/slides/2023-10-08-Revealjs-demo/
diff --git a/README.Rmd b/README.Rmd
index c0a9d2c..3efbb59 100644
--- a/README.Rmd
+++ b/README.Rmd
@@ -11,7 +11,7 @@
 
 ## Screenshots
 
-Generated from [examples/ids.Rmd](./examples/ids.Rmd).
+Generated from [examples/ids.Rmd](./examples/ids.Rmd), see live demo [here](http://10.0.1.45/slides/2023-10-08-Revealjs-demo/ids.html).
 
 ![title](https://gitlab.ids-mannheim.de/ids/revealjs/-/jobs/artifacts/main/raw/target/title.png?job=build-job)
 
diff --git a/README.md b/README.md
index df69357..766d096 100644
--- a/README.md
+++ b/README.md
@@ -12,7 +12,8 @@
 
 ## Screenshots
 
-Generated from [examples/ids.Rmd](./examples/ids.Rmd).
+Generated from [examples/ids.Rmd](./examples/ids.Rmd), see live demo
+[here](http://10.0.1.45/slides/2023-10-08-Revealjs-demo/ids.html).
 
 ![title](https://gitlab.ids-mannheim.de/ids/revealjs/-/jobs/artifacts/main/raw/target/title.png?job=build-job)