The configuration can be done by environment variables or by a yaml configuration file. For more complex scenario the yaml is recommended.
How to configure
The viewer allows two different ways to apply configuration.
Configuration by environment variables is for configurations that are small and modify only a few variables. It is easy and fast to create and apply these configurations.
Configuration with yaml is for more complex configurations and different instances with complete different configurations. A yaml is prepared and then mapped in the container like as configmap or volume mapping.
Configuration by environment variables
Example for docker compose file
version: '3' services: tiaviewer: container_name: tiaviewer image: images.docker.kgs-cloud.de/tia-viewer/archivelink-oidc:latest ports: - "8080:8080" environment: tia.destinations.saphttp.host: contentservevr.kgs.local tia.destinations.saphttp.port: 8090 tia.instances.default.watermark.text: copy tia.instances.default.sap.url: https://sapServer:8400/tia/tia_viewer?sap-client=250 tia.instances.default.sap.username: secuser tia.instances.default.sap.password: s3cret tia.instances.default.mimetypes.0: application/pdf
Configuration with yaml
Example for docker compose file
viewer.yaml:
tia: destinations: saphttp: host: contentservevr.kgs.local port: 8090 instances: default: watermark: text: "copy" sap: url: "https://sapServer:8400/tia/tia_viewer?sap-client=250" username: secuser password: s3cret mimetypes: - application/pdf HR: downloadDocument: false FI: text: "confidential" FO: printDocumentNote: false mimetypes.0: application/pdf
load the viewer.yaml in the container:
version: '3' services: tiaviewer: container_name: tiaviewer image: images.docker.kgs-cloud.de/tia-viewer/archivelink-oidc:latest ports: - "8080:8080" volumes: ./viewer.yml: /app/config/viewer.yml environment: spring.config.additional-location: /app/config/viewer.yml