Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Page Properties
hiddentrue
idDONE

Product Version
Report Note
Assignee

Resources & Remarks

Modification History

NameDateProduct VersionAction
Antje03 FEB 20222022 Springcreated
Agnieszka10 FEB 20222022 SpringrLANG
Antje23 MAY 20222022 Summeradd access via ingress


...

The service is delivered as docker container image.
>>Version Tags Services

As of 2022 Summer, the installation via Helm chart is possible as well.
>> Installation Guide

For the deployment to the yuuvis® Momentum cluster, you need a deployment and a service script as shown in the example code blocks below. The parameters have to be adjusted according to your own cluster. However, please use the /working-dir path for the PersistentVolumeClaim.

language
Code Block
ymltitleExample 'rm_service.yml'
linenumberstruecollapsetrue
apiVersion: v1
kind: Service
metadata:
  namespace: $NAMESPACE
  labels:
    app: yuuvis
    name: repositorymanager
    yuuvis: "true"
  name: repositorymanager
spec:
  ports:
    - name: "http"
      port: 80
      targetPort: 8010
  type: ClusterIP
  selector:
    name: repositorymanager


language
Code Block
collapse
ymltitleExample 'rm_deployment.yml'
linenumberstruetrue
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: data-repositorymanager
  namespace: $NAMESPACE
spec:
  storageClassName: local-path
  volumeMode: Filesystem
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 2Gi
---
apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: $NAMESPACE
  labels:
    app: yuuvis
    name: repositorymanager
  name: repositorymanager
spec:
  replicas: 1
  selector:
    matchLabels:
      name: repositorymanager
  template:
    metadata:
      labels:
        name: repositorymanager
    spec:
      containers:
        - name: repositorymanager
          image: docker.optimal-systems.org/team-kookaburra/$CI_PROJECT_NAME:commit-$CI_COMMIT_SHORT_SHA
          imagePullPolicy: Always
          env:
            - name: JAVA_OPTS
              value: -Xmx128m
            - name: SPRING_CLOUD_CONFIG_URI
              value: "http://configservice/config"
            - name: SPRING_PROFILES_ACTIVE
              value: prod,docker,kubernetes
          ports:
            - containerPort: 8010
          volumeMounts:
            - name: storage
              mountPath: /working-dir
      volumes:
        - name: storage
          persistentVolumeClaim:
            claimName: data-repositorymanager
      restartPolicy: Always
      imagePullSecrets:
        - name: osgitlab

...

Note: If your tests fail due to problems with the ILM protocol, please disable CORS

  • by configuring nginx.ingress.kubernetes.io/enable-cors: "false" in case you use Ingress controller or
  • in the loadbalancer of your cloud provider.

Access via NGINX Ingress Controller

...

Expose the REPOSITORYMANAGER service via a Kubernetes Node port to the local network. In the example configuration shown in the code block below, the REPOSITORYMANAGER service will be accessible in the local network by the IP address CLUSTER_IP:30036.

yml
Code Block
language
titleExample Kubernetes cluster configuration
linenumberstruecollapsetrue
kind: Service
apiVersion: v1
metadata:
 name: repositorymanager
 namespace: yuuvis
   app: yuuvis
   name: repositorymanager
   yuuvis: 'true'
spec:
 ports:
  - name: http
    protocol: TCP
    port: 80
    targetPort: 8010
    nodePort: 30036 # This should be unique value in range 30000-32767
 selector:
   name: repositorymanager
 type: NodePort

...

PropertyTypeDescriptionExample valueDefault value
repository-manager.barcode.default-docTypeString

Default SAP document type that is used if there is no barcode mapping for the yuuvis® Momentum content type (see repository-manager.barcode.cntType2docType).

TIFTIF
repository-manager.barcode.cntType2docTypeString

List of entries for mapping the barcode document type, separated by pipe characters. Entries consist of:yuuvis® Momentum content type, equals sign, SAP document type.

For each yuuvis® Momentum content type missing in the mapping list, the SAP document type repository-manager.barcode.cntType2docType is used.

Image/TIFF=FAX|application/pdf=PDFImage/TIFF=FAX|application/pdf=PDF
core.api.urlStringPublic URL of the yuuvis® Momentum authentication service.http://<yourserver>:<port>http://127.0.0.1:7301/
core.api.usernameString

Username of the technical user for the REPOSITORYMANAGER service's access to yuuvis® Momentum.

Note: The technical user requires full access rights to the objects.

saproot
core.api.passwordStringPassword of the technical user for the REPOSITORYMANAGER service's access to yuuvis® Momentum.optimal1optimal
core.api.tenantStringTenant of the technical user for the REPOSITORYMANAGER service's access to yuuvis® Momentum.defaultdefault
spring.activemq.broker-urlString

IP address and port used by ActiveMQ.

tcp://<yourserver>:<port>

tcp://127.0.0.1:61616
spring.activemq.userStringUser name for ActiveMQ access.adminadmin
spring.activemq.passwordStringPassword for ActiveMQ access.adminadmin

The following code block shows an example configuration.

yml
Code Block
language
titleExample 'repositorymanager-prod.yml' configuration file
linenumberstruecollapsetrue
repository-manager:
  barcode:
    cntType2docType: Image/TIFF=FAX|application/pdf=PDF
    default-docType: TIF
    
core:
  api:
    url: https://client.con.yuuvis.org
    username: root
    password: optimal
    tenant: default

spring:
  activemq:
    broker-url: tcp://repositorymanager-mq:61616
    user: admin
    password: admin

...

Create the namespace using the following YML script:

language
Code Block
ymltitlenamespace script
linenumberstruecollapsetrue
apiVersion: v1
kind: Namespace
metadata:
  name: repositorymanager-1 # This is an example value that has to be replaced by the name of your namespace you want to use for the additional repositorymanager service instance.

...

Deploy the repositorymanager-mq pod for ActiveMQ using the following two YML scripts:

language
Code Block
collapse
ymltitleMQ deployment script
linenumberstruetrue
apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: repositorymanager-1 # Change value to the namespace specified in the namespace script before.
  name: repositorymanager-mq
  labels:
    app: yuuvis
    name: repositorymanager-mq
spec:
  replicas: 1
  selector:
    matchLabels:
      name: repositorymanager-mq
  template:
    metadata:
      labels:
        name: repositorymanager-mq
    spec:
      containers:
        - image: docker.yuuvis.org/<image> # Change value
          name: repositorymanager-mq
          imagePullPolicy: Always
      restartPolicy: Always
      imagePullSecrets:
        - name: changeme # Change value

Note: This is an example script which requires the a specific secret to be present in the same namespace. Different clusters might require some changes.


yml
Code Block
language
titleMQ service script
linenumberstruecollapsetrue
apiVersion: v1
kind: Service
metadata:
  namespace: repositorymanager-1
  name: repositorymanager-mq
  labels:
    app: yuuvis
    name: repositorymanager-mq
spec:
  selector:
    name: repositorymanager-mq
  ports:
    - name: dashboard
      port: 8161
      nodePort: 30001
    - name: openwire
      port: 61616
      nodePort: 30002
  type: NodePort

...

Deploy the repositorymanager service using the following two YML scripts:

yml
Code Block
language
titleService deployment script
linenumberstruecollapsetrue
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: data-repositorymanager
  namespace: repositorymanager-1
spec:
  storageClassName: local-path
  volumeMode: Filesystem
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 10Gi
---
apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: repositorymanager-1
  labels:
    app: yuuvis
    name: repositorymanager
  name: repositorymanager
spec:
  replicas: 1
  selector:
    matchLabels:
      name: repositorymanager
  template:
    metadata:
      labels:
        name: repositorymanager
    spec:
      containers:
        - name: repositorymanager
          image: docker.optimal-systems.org/team-kookaburra/repositorymanager-momentum:commit-2d346b0e
          imagePullPolicy: Always
          env:
            - name: JAVA_OPTS
              value: -Xmx128m
            - name: SPRING_CLOUD_CONFIG_URI
              value: "http://configservice.yuuvis/config"
            - name: SPRING_PROFILES_ACTIVE
              value: instance1,docker,kubernetes
          ports:
            - containerPort: 8010
          volumeMounts:
            - name: storage
              mountPath: /working-dir
      volumes:
        - name: storage
          persistentVolumeClaim:
            claimName: data-repositorymanager
      restartPolicy: Always
      imagePullSecrets:
        - name: osgitlab

Note: This script uses the image from OS GitLab which requires the osgitlab secret to be present in the same namespace. Different clusters might require some changes. Additionally, the environment parameter SPRING_CLOUD_CONFIG_URI should point to the CONFIGSERVICE of the specific cluster. The SPRING_PROFILES_ACTIVE environment variable should contain the docker and kubernetes profiles as well as the service profile dedicated to that instance, in this case instance1.

Code Block
languageyml
titleservice script
linenumberstruecollapsetrue
apiVersion: v1
kind: Service
metadata:
  namespace: repositorymanager-1
  labels:
    app: yuuvis
    name: repositorymanager
    yuuvis: "true"
  name: repositorymanager
spec:
  ports:
    - name: "http"
      port: 80
      targetPort: 8010
      nodePort: 30000
  type: NodePort
  selector:
    name: repositorymanager

...

The following code block shows an example for the configuration:

Code Block
languageyml
titlerepositorymanager-instance1.yml
linenumberstruecollapsetrue
core:
  api:
    url: http://client.yuuvis
    username: root
    password: optimal
    tenant: instance1tenant

spring:
  activemq:
    broker-url: tcp://repositorymanager-mq:61616

...