<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>subkom Wissensdatenbank – Übersicht</title><link>/docs/</link><description>Recent content in Übersicht on subkom Wissensdatenbank</description><generator>Hugo -- gohugo.io</generator><language>de</language><atom:link href="/docs/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: Smartbib Installation mit HELM</title><link>/docs/smartbib/smartbib-k8s-install/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/smartbib/smartbib-k8s-install/</guid><description>
&lt;h2 id="einleitung">Einleitung&lt;/h2>
&lt;p>Dieses Tutorial dient als Step-by-Step Anleitung und zeigt wie man Smartbib in einer Kubernetes Umgebung installieren kann.&lt;/p>
&lt;p>Für die Installationanleitung wird MicroK8s von Canonical verwendet. &lt;a href="https://microk8s.io/">https://microk8s.io/&lt;/a>&lt;/p>
&lt;h2 id="snap-installieren">SNAP installieren&lt;/h2>
&lt;p>Für die generelle Installation ist &lt;strong>snap&lt;/strong> (&lt;a href="https://snapcraft.io/">https://snapcraft.io/&lt;/a>) erforderlich, da &lt;strong>microk8s&lt;/strong> über den Snap Store verfügbar ist.&lt;/p>
&lt;p>In den meisten Ubuntu-basierten Distributionen ist der &lt;strong>snapd&lt;/strong> Daemon bereits vorinstalliert.&lt;/p>
&lt;p>Falls man andere Distributionen verwenden möchte, dann findet man unter &lt;a href="https://snapcraft.io/docs/installing-snapd">https://snapcraft.io/docs/installing-snapd&lt;/a> die notwendigen Installationsschritte.&lt;/p>
&lt;p>So gibt es z.B. &lt;strong>snapd&lt;/strong> ab &lt;strong>Debian 9 (Strech)&lt;/strong> bereits als APT Package.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo apt install snapd
&lt;/code>&lt;/pre>&lt;h2 id="microk8s">Microk8s&lt;/h2>
&lt;h3 id="micro-kubernetes-installieren">Micro Kubernetes installieren&lt;/h3>
&lt;p>Es kann nun microk8s in der aktuellen Version mit Hilfe von Snap über installiert werden.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo snap install microk8s --classic
&lt;/code>&lt;/pre>&lt;h4 id="alternativ-version-festlegen">Alternativ: Version festlegen&lt;/h4>
&lt;p>Sollte man eine spezielle Kubernetes Version verwenden wollen, so kann man dies alternativ über die Angabe des Channels festlegten.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo snap install microk8s --classic --channel=1.19/stable
&lt;/code>&lt;/pre>&lt;p>Die verfügbaren Channels kann man sich mit &lt;code>snap info microk8s&lt;/code> anzeigen lassen.&lt;/p>
&lt;h3 id="berechtigungen-für-aktuellen-user-setzen">Berechtigungen für aktuellen User setzen&lt;/h3>
&lt;p>Wenn man nicht mit &lt;strong>sudo&lt;/strong> sondern direkt mit dem aktuellen Benutzer einen Zugriff auf die kubernetes Installation haben möchte, dann empfiehlt sich eine Anpassung der Benutzerberechtigungen.&lt;/p>
&lt;p>Folgender Befehl gibt dem aktuellen User die erforderliche Gruppenberechtigung.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo usermod -a -G microk8s $USER
&lt;/code>&lt;/pre>&lt;h3 id="alias-setzen">Alias setzen&lt;/h3>
&lt;p>Grundsätzlich sind nun alle kubernetes Commands per &lt;strong>microk8s.&lt;/strong> Prefix über die Shell verfügbar. (z.B. microk8s.kubectl)&lt;/p>
&lt;p>Bei häufig genutzen Commands - wie dies bei &lt;strong>kubectl&lt;/strong> meist der Fall ist - empfiehlt es sich, dass man Shell Aliase setzt.&lt;/p>
&lt;p>Hier ein Beispiel, falls man BASH verwendet:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ echo &amp;#34;alias kubectl=&amp;#39;microk8s.kubectl&amp;#39;&amp;#34; &amp;gt;&amp;gt; ~/.bash_aliases
$ echo &amp;#34;alias helm=&amp;#39;microk8s.helm&amp;#39;&amp;#34; &amp;gt;&amp;gt; ~/.bash_aliases
&lt;/code>&lt;/pre>&lt;p>Nach der Neuanmeldung stehen dann die Aliase zur Verfügung.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ su - $USER
&lt;/code>&lt;/pre>&lt;h3 id="microk8s-module-installieren">Microk8s Module installieren&lt;/h3>
&lt;p>Nun können erforderliche MicroK8s Module aktiviert werden.&lt;/p>
&lt;p>Für die Smartbib-Installation werden folgende Module benötigt:&lt;/p>
&lt;ul>
&lt;li>dns: CoreDNS (verwendet als Default 8.8.8.8 u.w. als Upstream DNS)&lt;/li>
&lt;li>storage: Dateipfade des Hosts werden als Storage zur Verfügung gestellt&lt;/li>
&lt;li>ingress: NGINX Ingress Controller (für Namesbaisertes Virtual Hosting)&lt;/li>
&lt;/ul>
&lt;p>Die Module können mit folgendem Befehl installiert werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ microk8s.enable dns storage ingress
&lt;/code>&lt;/pre>&lt;h2 id="helm--und-docker-repository">HELM- und Docker-Repository&lt;/h2>
&lt;p>Um das Deployment von Smartbib zu vereinfachen wird der Package Manager &lt;strong>helm&lt;/strong> (&lt;a href="https://helm.sh/">https://helm.sh/&lt;/a>) verwendet.&lt;/p>
&lt;p>Wir stellen für Smartbib ein &lt;strong>helm&lt;/strong> und &lt;strong>docker&lt;/strong>-repository zur Verfügung:&lt;/p>
&lt;ul>
&lt;li>docker: &lt;a href="https://registry.smartbib.net">https://registry.smartbib.net&lt;/a>&lt;/li>
&lt;li>helm: &lt;a href="https://registry.smartbib.net/charts/">https://registry.smartbib.net/charts/&lt;/a>&lt;/li>
&lt;/ul>
&lt;p>Für den Zugriff benötigen Sie einen Benutzernamen und ein Passwort.&lt;br>
Bei folgenden Anleitungen werden hierfür die Environment-Variablen &lt;code>$USERNAME&lt;/code> und &lt;code>$PASSWORD&lt;/code> verwendet.&lt;/p>
&lt;h3 id="helm-package-manager-installieren">HELM Package Manager installieren&lt;/h3>
&lt;p>Der aktuelle HELM Package Manger kann per microk8s.enable oder SNAP installiert werden.&lt;br>
Die integrierte Version in microk8s ist jedoch meist etwas veraltet.&lt;br>
Aus diesem Grund wird die Installation mit &lt;strong>snap&lt;/strong> gewählt:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo snap install helm --classic
&lt;/code>&lt;/pre>&lt;p>Damit der HELM Package Manager - ohne weitere Konfiguration - Zugriff auf die MicroK8s Installation erhält, kann ein symbolischer Link in der &lt;em>microk8s&lt;/em>-Installlation angelegt werden.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ sudo mkdir -p /var/snap/microk8s/current/bin
$ sudo ln -s /snap/bin/helm /var/snap/microk8s/current/bin/helm
&lt;/code>&lt;/pre>&lt;h3 id="smartbib-helm-repository-hinzufügen">Smartbib Helm Repository hinzufügen&lt;/h3>
&lt;p>Ihre Zugangsdaten müssen sich in den Environment-Variablen &lt;code>$USERNAME&lt;/code> und &lt;code>$PASSWORD&lt;/code> befinden.&lt;/p>
&lt;p>Hinzufügen das Smartbib HELM Repositories:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ helm repo add smartbib https://registry.smartbib.net/charts/ --username $USERNAME --password $PASSWORD
$ helm repo update
&lt;/code>&lt;/pre>&lt;p>Das Helm Respostory kann nun kurz mit folgendem Befehl geprüft werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ helm search repo
&lt;/code>&lt;/pre>&lt;h3 id="docker-repositiory-credentials-setzen">Docker Repositiory Credentials setzen&lt;/h3>
&lt;pre tabindex="0">&lt;code>$ kubectl create secret docker-registry regcred --docker-server=registry.smartbib.net --docker-username=$USERNAME --docker-password=$PASSWORD
&lt;/code>&lt;/pre>&lt;h2 id="optional-cert-manager-installieren">Optional: Cert-Manager installieren&lt;/h2>
&lt;p>Um die Ausstellung von Zertifikaten zu vereinfachen, kann für Kubernetes der Cert-Manager (&lt;a href="https://cert-manager.io">https://cert-manager.io&lt;/a>) verwendet werden.&lt;/p>
&lt;p>Im folgenden Beispiel wird der Cert-Manager mit Hilfe des HELM Package Managers installiert und es werden Issuer für Letscrypt-Zertikatsausstellungen (production und staging) angelegt.&lt;br>
Es wird dabei der HTTP Solver verwendet.&lt;/p>
&lt;p>Nach Abschluss wird es dann möglich sein, dass die automatische Zertifkatserstellung direkt per Annotation bei der Ingress Definition hinterlegt werden kann.&lt;/p>
&lt;h3 id="helm-repository-hinzufügen">Helm Repository hinzufügen&lt;/h3>
&lt;p>Der Cert-Manager kann sehr einfach über HELM depolyed werden.&lt;br>
Als erster Schritt muss hierfür das Jetstack HELM-Repository hinzugefügt werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ helm repo add jetstack https://charts.jetstack.io
$ helm repo update
&lt;/code>&lt;/pre>&lt;h3 id="cert-manager-mit-helm-installieren">Cert-Manager mit HELM installieren&lt;/h3>
&lt;p>Nun kann der Cert-Manager bereit gestellt werden.&lt;br>
Es bietet sich hier die Verwendung eines eigenen Namespaces (z.B. cert-manager) an.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ kubectl create namespace cert-manager
$ helm install cert-manager jetstack/cert-manager --namespace cert-manager --version v1.1.0 --set installCRDs=true
&lt;/code>&lt;/pre>&lt;h3 id="create-letsencrypt-certificate-issuers">Create Letsencrypt Certificate Issuers&lt;/h3>
&lt;p>Es werden nun die Issuer für die Zertifikat-Requests erstellt.&lt;br>
Es wird ein &lt;em>ClusterIssuer&lt;/em> verwendet, der namespace-übergreifend funktioniert, aber die Verwendung des &lt;em>Issuer&lt;/em> ist genauso möglich.&lt;br>
Im Folgenden werden 2 neue YAML Dateien angelegt, die für Production und für Staging-Requests genutzt werden können.&lt;/p>
&lt;p>Die Email-Adresse muss entsprechend angepasst werden.&lt;br>
Im Beispiel wird ein HTTP Challenge Solver verwendet.&lt;/p>
&lt;h4 id="production">Production&lt;/h4>
&lt;p>&lt;strong>letsencrypt-cluster-issuer.yaml&lt;/strong>&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#204a87;font-weight:bold">apiVersion&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">cert-manager.io/v1alpha2&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">kind&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">ClusterIssuer&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">metadata&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">name&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">spec&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">acme&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># You must replace this email address with your own.&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Let&amp;#39;s Encrypt will use this to contact you about expiring&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># certificates, and issues related to your account.&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">email&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">email@example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">server&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">https://acme-v02.api.letsencrypt.org/directory&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">privateKeySecretRef&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Secret resource that will be used to store the account&amp;#39;s private key.&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">name&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt-account-key&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Add a single challenge solver, HTTP01 using nginx&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">solvers&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#204a87;font-weight:bold">http01&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">class&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">nginx&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h4 id="staging">Staging&lt;/h4>
&lt;p>&lt;strong>letsencrypt-staging-cluster-issuer.yaml:&lt;/strong>&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#204a87;font-weight:bold">apiVersion&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">cert-manager.io/v1alpha2&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">kind&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">ClusterIssuer&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">metadata&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">name&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt-staging&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">spec&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">acme&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">email&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">email@example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">server&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">https://acme-staging-v02.api.letsencrypt.org/directory&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">privateKeySecretRef&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">name&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt-staging-account-key&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">solvers&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#204a87;font-weight:bold">http01&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">class&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">nginx&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h3 id="letencrypt-issuers">Letencrypt Issuers&lt;/h3>
&lt;p>Nun können die 2 Issuers mit Hilfe von &lt;code>kubectl apply&lt;/code> hinzugefügt werden.&lt;/p>
&lt;pre tabindex="0">&lt;code>$ kubectl apply -f letsencrypt-cluster-issuer.yaml
$ kubectl apply -f letsencrypt-staging-cluster-issuer.yaml
&lt;/code>&lt;/pre>&lt;h3 id="verwenden-der-issuer">Verwenden der Issuer&lt;/h3>
&lt;p>Nun können die Issuer in den Annotations der Ingress Konfguration verwendet werden:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">...&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">annotations&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">cert-manager.io/cluster-issuer&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>oder&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">...&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">annotations&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">cert-manager.io/cluster-issuer&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt-staging&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h2 id="yaml-konfiguration-für-helm-erzeugen">YAML Konfiguration für HELM erzeugen&lt;/h2>
&lt;p>Nun muss eine HELM Konfiguration erstellt werden oder sie erhalten eine vorkonfigurierte Datei.&lt;/p>
&lt;p>Im folgenden Texten und Dateiausschnitten wird der Begriff &lt;strong>CUSTOMER_TOKEN&lt;/strong> verwendet.&lt;br>
An all diesen Stellen sollten sie ihr eigenes TOKEN angeben, dass sie von uns erhalten haben.&lt;/p>
&lt;p>&lt;strong>CUSTOMER_TOKEN.yaml&lt;/strong>:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"># Wichtig: Token setzen&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">customer&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">CUSTOMER_TOKEN &lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">solr&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">keep&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">true&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Solr Index auch beim Löschen des Charts behalten&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Ingress für namebased virtual hosting und Letscrypt Certificate Requests&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">enabled&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">true&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">annotations&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">cert-manager.io/cluster-issuer&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">letsencrypt&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">hosts&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#204a87;font-weight:bold">host&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">smartbib.example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">paths&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000;font-weight:bold">[&lt;/span>&lt;span style="color:#4e9a06">&amp;#34;&amp;#34;&lt;/span>&lt;span style="color:#000;font-weight:bold">]&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">tls&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#204a87;font-weight:bold">secretName&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">smartbib.example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">hosts&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#000">smartbib.example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Optional: BibConnector Konfigurationen&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">bibcon&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">enabled&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">true&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">configFiles&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">data&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">bibConnector.xml&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000;font-weight:bold">|-&lt;/span>&lt;span style="color:#8f5902;font-style:italic">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;configuration&amp;gt;
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;bibConnector&amp;gt;BIBL&amp;lt;/bibConnector&amp;gt;
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> ...
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;port&amp;gt;8040&amp;lt;/port&amp;gt;
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;/configuration&amp;gt;&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">BIBL.xml&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000;font-weight:bold">|-&lt;/span>&lt;span style="color:#8f5902;font-style:italic">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;configuration&amp;gt;
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> ...
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#8f5902;font-style:italic"> &amp;lt;/configuration&amp;gt;&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h2 id="nur-http-ingress-verwenden">Nur HTTP Ingress verwenden&lt;/h2>
&lt;p>Falls der Cert-Manager nicht verwendet wird und die Zertifikatsausstellung an anderer Stelle, z.B. durch einen Proxy erledigt wird,
dann ist es möglich, dass man die automatische HTTP -&amp;gt; HTTPS Weiterleitung deaktivieren kann.&lt;br>
Hierfür muss eine Annotation hinzugefügt werden: &lt;code>nginx.ingress.kubernetes.io/ssl-redirect: &amp;quot;false&amp;quot;&lt;/code>.&lt;br>
Auf den Block &lt;strong>tls&lt;/strong> kann nun komplett verzichtet werden.&lt;/p>
&lt;p>Beispiel:&lt;/p>
&lt;div class="highlight">&lt;pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-yaml" data-lang="yaml">&lt;span style="display:flex;">&lt;span>&lt;span style="color:#000">...&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#8f5902;font-style:italic"># Ingress für namebased virtual hosting und Letscrypt Certificate Requests&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#204a87;font-weight:bold">ingress&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">enabled&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">true&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">annotations&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">nginx.ingress.kubernetes.io/ssl-redirect&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#4e9a06">&amp;#34;false&amp;#34;&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">hosts&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>- &lt;span style="color:#204a87;font-weight:bold">host&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000">smartbib.example.com&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#204a87;font-weight:bold">paths&lt;/span>&lt;span style="color:#000;font-weight:bold">:&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline"> &lt;/span>&lt;span style="color:#000;font-weight:bold">[&lt;/span>&lt;span style="color:#4e9a06">&amp;#34;&amp;#34;&lt;/span>&lt;span style="color:#000;font-weight:bold">]&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#f8f8f8;text-decoration:underline">&lt;/span>&lt;span style="color:#000">...&lt;/span>&lt;span style="color:#f8f8f8;text-decoration:underline">
&lt;/span>&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h2 id="smartbib-starten">Smartbib starten&lt;/h2>
&lt;pre tabindex="0">&lt;code>$ helm install smartbib-CUSTOMER_TOKEN smartbib/smartbib -f CUSTOMER_TOKEN.yaml
&lt;/code>&lt;/pre>&lt;h3 id="installation-prüfen">Installation prüfen&lt;/h3>
&lt;p>Zuerst sollte man warten bis alle Pods gestartet wurden:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ kubectl get pods -w
&lt;/code>&lt;/pre>&lt;p>(Abbruch mit Strg+C)&lt;/p>
&lt;h2 id="zugriff-auf-die-logs">Zugriff auf die Logs&lt;/h2>
&lt;h3 id="env-variable-erstellen">ENV Variable erstellen&lt;/h3>
&lt;p>Im ersten Schritt ist es hilfreich, dass man eine Environment Variable erstellt, damit man den HASH des Pods nicht per Hand eingeben muss:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ export SMARTBIB_POD=$(microk8s.kubectl get pods --namespace default -l &amp;#34;app.kubernetes.io/name=smartbib,app.kubernetes.io/instance=smartbib-CUSTOMER_TOKEN&amp;#34; -o jsonpath=&amp;#34;{.items[0].metadata.name}&amp;#34;)
&lt;/code>&lt;/pre>&lt;p>(smartbib-CUSTOMER_TOKEN muss entsprechend angepasst werden)&lt;/p>
&lt;h3 id="logs-anzeigenverfolgen">Logs anzeigen/verfolgen&lt;/h3>
&lt;p>Hier ein Bespiel wie man z.b die BibConnector-Ausgabe einsehen kann:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ kubectl logs $SMARTBIB_POD -c bibcon -f
&lt;/code>&lt;/pre>&lt;p>Eine komplette Liste aller Möglichkeiten erhält man, wenn man den &lt;strong>-c&lt;/strong> Parameter weglässt:&lt;/p>
&lt;pre tabindex="0">&lt;code>$ kubectl logs $SMARTBIB_POD
&lt;/code>&lt;/pre></description></item><item><title>Docs: Smartbib Installation unter SuSE Linux Enterprise</title><link>/docs/smartbib/smartbib-native-linux-install/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>/docs/smartbib/smartbib-native-linux-install/</guid><description>
&lt;h2 id="einleitung">Einleitung&lt;/h2>
&lt;p>Dieses Tutorial zeigt wie man Smartbib unter SuSE Linux Enterprise installieren kann.&lt;/p>
&lt;p>Diese Methode bietet sich für alle Installationen an, bei denen keine Container genutzt werden oder nur ein beschränkter Internet-Zugang verfügbar ist.&lt;/p>
&lt;h2 id="basis-installation-suse">Basis-Installation SuSE&lt;/h2>
&lt;p>Für diese Dokumentation wurde SLES 15 SP 2 in einer Oracle VirtualBox VM installiert. (&lt;a href="https://www.suse.com/download/sles/">https://www.suse.com/download/sles/&lt;/a>)&lt;/p>
&lt;p>Es wurde bei der Erstellung darauf Wert gelegt, dass nach Möglichkeit nur das offizielle Installations-Medium für die notwendigen SuSE Package verwendet wird und für den kompletten Installations-Vorgang keine Internet-Verbindung erforderlich ist.&lt;/p>
&lt;h3 id="installierte-suse-module">Installierte SuSE Module&lt;/h3>
&lt;ul>
&lt;li>Basesystem&lt;/li>
&lt;li>Development Tools&lt;/li>
&lt;li>Server Applications&lt;/li>
&lt;li>Web and Scripting&lt;/li>
&lt;/ul>
&lt;h3 id="suse-firewall-einstellungen">SuSE Firewall-Einstellungen&lt;/h3>
&lt;pre tabindex="0">&lt;code>firewall-cmd --permanent --add-service=ssh
firewall-cmd --permanent --zone=public --add-service=http
firewall-cmd --permanent --zone=public --add-port=8983/tcp
firewall-cmd --permanent --reload
firewall-cmd --permanent --list-all
&lt;/code>&lt;/pre>&lt;h2 id="smartbib-benutzer-anlegen">Smartbib Benutzer anlegen&lt;/h2>
&lt;pre tabindex="0">&lt;code>groupadd smartbib
useradd -G smartbib smartbib
&lt;/code>&lt;/pre>&lt;h2 id="suse-pakete-installieren">SuSE Pakete installieren&lt;/h2>
&lt;p>Für die Installation der SuSE Pakete wurde &lt;em>zypper&lt;/em> verwendet:&lt;/p>
&lt;h3 id="java-installieren">Java installieren&lt;/h3>
&lt;pre tabindex="0">&lt;code>zypper in java-11-openjdk
&lt;/code>&lt;/pre>&lt;h3 id="mariadb-installieren-und-aktivieren">MariaDB installieren und aktivieren&lt;/h3>
&lt;p>MariaDB mit Hilfe von zypper installieren&lt;/p>
&lt;pre tabindex="0">&lt;code>zypper in mariadb
&lt;/code>&lt;/pre>&lt;p>Den Systemd Service aktivieren und starten&lt;/p>
&lt;pre tabindex="0">&lt;code>systemctl enable mariadb
systemctl start mariadb
&lt;/code>&lt;/pre>&lt;p>Für die aktuelle Smartbib-Installation ist es notwendig, dass die Socket-Authentification deaktivert wird und stattdessen ein Root-Passwort gesetzt wird.
Die kann mit Hilfe von &lt;strong>mysql_secure_installation&lt;/strong> vorgenommen werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>mysql_secure_installation
&lt;/code>&lt;/pre>&lt;h3 id="apache2-mit-php-und-weitere-pakete">Apache2 mit PHP und weitere Pakete&lt;/h3>
&lt;pre tabindex="0">&lt;code>zypper in zip apache2 yast2-http-server apache2-mod_php7 php7-mbstring php7-pear php7 php7-devel php7-gd php7-intl php7-json php7-ldap php7-mysql php7-curl php7-xmlreader php7-xmlrpc php7-xmlwriter php7-soap php7-curl php7-xsl php7-zlib
&lt;/code>&lt;/pre>&lt;p>Über &lt;em>yast&lt;/em> kann der Apache2 konfiguriert werden: Netzwerkdienste -&amp;gt; HTTP-Server&lt;/p>
&lt;pre tabindex="0">&lt;code>yast
&lt;/code>&lt;/pre>&lt;p>Es können generell alle Standardeinstellungen verwendet werden, da weitere Einstellungen über die Konsole durchgeführt werden.&lt;/p>
&lt;p>Notwendige Einstelungen über YaST: Der Firewall-Port sollte geöffnet werden und &lt;strong>PHP muss generell aktiviert werden&lt;/strong>.&lt;/p>
&lt;h4 id="apache-module-aktivieren-rewrite-und-env">Apache Module aktivieren: Rewrite und Env&lt;/h4>
&lt;p>Es ist notwendig, die Apache-Module &lt;strong>rewrite&lt;/strong> und &lt;strong>env&lt;/strong> zu aktivieren:&lt;/p>
&lt;pre tabindex="0">&lt;code>a2enmod rewrite
a2enmod env
systemctl restart apache2
&lt;/code>&lt;/pre>&lt;h2 id="smartbib-installation">Smartbib Installation&lt;/h2>
&lt;p>Alle notwendigen Dateien für Smartbib werden mit TAR-Paketen bereitgestellt:&lt;/p>
&lt;p>Beispiele:&lt;/p>
&lt;ul>
&lt;li>smartbib-drv-complete-with-config-7.1.0.tar.gz&lt;/li>
&lt;li>smartbib-drv-complete-7.1.0.tar.gz&lt;/li>
&lt;/ul>
&lt;p>Für die erste Installation sollte das Paket &lt;em>-with-config-&lt;/em> verwendet werden, da hier schon vorgefertigte Kunden-Konfgurationen enhalten sind.&lt;/p>
&lt;h2 id="entpacken-nach-usrlocalsmartbib">Entpacken nach /usr/local/smartbib&lt;/h2>
&lt;p>Das bereitgestellte Archiv sollte im &lt;em>/usr/local/&lt;/em> Verzeichnis entpackt werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>tar -xz -C /usr/local/ -f smartbib-drv-complete-with-config-7.1.0-beta.tar.gz
&lt;/code>&lt;/pre>&lt;h2 id="mariadb-tabelle-anlegen">MariaDB Tabelle anlegen&lt;/h2>
&lt;p>Mit folgendem SQL Skript wird eine neue Datenbank &lt;em>smartbib&lt;/em> und ein Benutzer &lt;em>smartbib&lt;/em> erstellt.
Es werden auch alle notwendigen Tabellen erstellt.&lt;/p>
&lt;pre tabindex="0">&lt;code>mysql &amp;lt; /usr/local/smartbib/setup/setup-smartbib.sql
&lt;/code>&lt;/pre>&lt;p>Es werden bereits vordefinierte Passwörter gesetzt und sind in entsprechende Smartbib INI Dateien eingetragen. Falls ein andere Passwort verwendet wird, dann muss dies auch in der Datei &lt;em>/usr/local/smartbib/vufind/local/config/vufind/config.ini&lt;/em> angepasst werden.&lt;/p>
&lt;h2 id="record-manager-tabelle-anlegen">Record-Manager Tabelle anlegen&lt;/h2>
&lt;p>Für den Daten-Import bei Verbund-System kommt der RecordManager zu Einsatz, damit eine Dubletten-Erkennung stattfindet.&lt;/p>
&lt;p>Der RecordManager kann dabei entweder MongoDB oder MySQL/MariaDB verwenden.&lt;br>
Da keine offiziellen SuSE Pakete für MongoDB bereitstehen, die offline installiert wird bei SuSE-Linux die MariaDB-Variante verwendet.&lt;/p>
&lt;p>Die notwendige Tabellenstruktur kann mit folgendem SQL Skript erstellt werden:&lt;/p>
&lt;pre tabindex="0">&lt;code>mysql &amp;lt; /usr/local/smartbib/setup/setup-recman.sql
&lt;/code>&lt;/pre>&lt;p>Es werden bereits vordefinierte Passwörter gesetzt und sind in entsprechende RecordManager INI Dateien eingetragen. Falls ein anderes Passwort verwendet wird, dann muss dies auch in der Datei &lt;em>/usr/local/smartbib/recordmanager/conf/recordmanager.ini&lt;/em> angepasst werden.&lt;/p>
&lt;h2 id="setup-starten">Setup starten&lt;/h2>
&lt;p>Es existert ein Setup-Shell-Skript, dass die restlichen Anpassungen vornimmt.&lt;/p>
&lt;p>Dazu zählen die Dateiberechtigungen, das Anlegen der Log-Verzeichnisse, das Starten von Systemd-Services und Timern und das Aktivieren unter Apache2.&lt;/p>
&lt;pre tabindex="0">&lt;code>cd /usr/local/smartbib/setup/
./setup.sh
&lt;/code>&lt;/pre>&lt;p>Sollte dieses automatische Vorgehen eher unerwünscht sein, dann können diese Schritte auch alternativ einzeln anhand der folgenden Anweisungen durchgeführt werden.&lt;/p>
&lt;h2 id="alternativ-manuelles-setup">Alternativ: Manuelles Setup&lt;/h2>
&lt;p>&lt;strong>Die folgenden Anweisungen müssen nur durchgeführt werden, wenn auf die Anwendung von &lt;em>setup.sh&lt;/em> verzichtet wird!&lt;/strong>&lt;/p>
&lt;h3 id="zugriffsrechte-setzen">Zugriffsrechte setzen&lt;/h3>
&lt;pre tabindex="0">&lt;code>chown -R smartbib:smartbib /usr/local/smartbib
chown -R wwwrun:smartbib /usr/local/smartbib/vufind/local/cache
chown -R wwwrun:smartbib /usr/local/smartbib/vufind/local/config
mkdir /usr/local/smartbib/vufind/local/cache/cli
chmod 777 /usr/local/smartbib/vufind/local/cache/cli
&lt;/code>&lt;/pre>&lt;h3 id="log-verzeichnis-erstellen">Log-Verzeichnis erstellen&lt;/h3>
&lt;pre tabindex="0">&lt;code>mkdir -p /var/log/smartbib/
chown -R wwwrun:smartbib /var/log/smartbib/
chmod g+w /var/log/smartbib/
&lt;/code>&lt;/pre>&lt;h3 id="smartbibsolr-systemd-service-aktivieren-und-starten">Smartbib/SOLR Systemd Service aktivieren und starten&lt;/h3>
&lt;pre tabindex="0">&lt;code>systemctl enable /usr/local/smartbib/service/smartbib-solr.service
systemctl start smartbib-solr.service
&lt;/code>&lt;/pre>&lt;h3 id="systemd-timer-für-converter-importer-und-indexgenerierung">Systemd Timer für Converter, Importer und Indexgenerierung&lt;/h3>
&lt;pre tabindex="0">&lt;code>systemctl enable /usr/local/smartbib/service/smartbib-convert.service
systemctl enable /usr/local/smartbib/service/smartbib-convert.timer
systemctl start smartbib-convert.timer
systemctl enable /usr/local/smartbib/service/smartbib-import.service
systemctl enable /usr/local/smartbib/service/smartbib-import.timer
systemctl start smartbib-import.timer
systemctl enable /usr/local/smartbib/service/smartbib-index-browse.service
systemctl enable /usr/local/smartbib/service/smartbib-index-browse.timer
systemctl start smartbib-index-browse.timer
&lt;/code>&lt;/pre>&lt;h3 id="apache-konfigurieren">Apache konfigurieren&lt;/h3>
&lt;pre tabindex="0">&lt;code>ln -s /usr/local/smartbib/service/httpd-smartbib.conf /etc/apache2/conf.d/smartbib.conf
systemctl restart apache2
&lt;/code>&lt;/pre>&lt;h2 id="daten-importieren">Daten importieren&lt;/h2>
&lt;p>Die Daten-Dateien müssen im Verzeichnis &lt;em>/usr/local/smartbib/import-data/upload/&lt;/em> abgelegt werden und werden dann mit Hilfe von Systemd-Timern verarbeitet.
Der Benutzer &lt;em>smartbib&lt;/em> muss Lese- und Schreibrechte für diese Datei besitzen.
Die Daten werden dann nachts automatisch verarbeitet.&lt;/p>
&lt;p>Die Liste der Timer kann man sich mit &lt;em>systemctl&lt;/em> anzeigen lassen:&lt;/p>
&lt;pre tabindex="0">&lt;code>systemctl list-timers
&lt;/code>&lt;/pre>&lt;p>Möchte man schon vorher die Vorgänge starten, kann man dies mit Hilfe der hinterlegten Systemd-Services erledigen.&lt;/p>
&lt;pre tabindex="0">&lt;code># Konvertierung
systemctl start smartbib-convert
# Dubletten-Erkennung + SOLR Import
systemctl start smartbib-import
# Erstellen des alphabetischen Suche-Index
systemctl start smartbib-index-browse
&lt;/code>&lt;/pre>&lt;p>Mit entsprechenden &lt;em>journalctl&lt;/em> Aufrufen können die Vorgänge geprüft werden.&lt;/p>
&lt;p>Beispiel: Verfolgen des aktuell laufenden Imports:&lt;/p>
&lt;pre tabindex="0">&lt;code>journalctl -u smartbib-import -f
&lt;/code>&lt;/pre>&lt;h2 id="log-dateien-überprüfen">Log-Dateien überprüfen&lt;/h2>
&lt;p>Im Verzeichnis &lt;em>/var/log/smartbib/&lt;/em> befinden sich alle Log-Dateien.&lt;/p>
&lt;p>Neben generellen Smartbib PHP Logs und SOLR-Log-Dateien findet man hier auch die Log-Dateien der Konvertierungen (&lt;em>convert/&lt;/em>) und Import-Vorgänge (&lt;em>recman&lt;/em>).&lt;/p>
&lt;h2 id="weitere-konfigurationen">Weitere Konfigurationen&lt;/h2>
&lt;p>Weitere Konfigurationen müssen dann entsprechend der Anforderungen vorgenommen werden und finden sich in der Regel im &lt;em>/usr/local/smartbib/vufind/local/config/vufind/&lt;/em> Verzeichnis.&lt;/p>
&lt;p>Die E-Mail-Konfiguration ist Standardmäßig auf &lt;em>localhost&lt;/em> eingestellt und wird dadurch durch einen lokal installierten Postfix-Service entgegengenommen.
Andere E-Mail-Einstellungen können auch direkt über die &lt;em>config.ini&lt;/em> vorgenommen werden.&lt;/p>
&lt;p>Die vorliegende Anleitung soll nur als grobe Struktur für die Installation dienen.&lt;/p></description></item></channel></rss>