/report-task

Docker container for creating MDM reports

Primary LanguageTeXGNU Affero General Public License v3.0AGPL-3.0

Build and DeploycodecovKnown Vulnerabilities

Report Task

This repository contains the implementation for a containerized Spring Cloud Task. The task generates reports by getting the relevant data from our MDM, compiling a PDF and uploading it to the MDM. Currently the task is started by the MDM via the AWS Fargate API and the MDM sends an E-Mail on task completion.

Developers

Developers need to have at least maven and docker on their machines. Currently you need to install java 15 sdk on your system. On Ubuntu you should use SDKMAN!.

The following environment variables have to be set for running the JUnit test:

MDM_ENDPOINT=https://dev.metadata.fdz.dzhw.eu
MDM_TASK_USER=taskuser
MDM_TASK_PASSWORD=**** (see s3://metadatamanagement-private/sensitive_variables.tf)

The docker image can be build with:

mvn -Pdev clean install

If you want to run the task against an MDM instance running on your local machine, you can run:

docker run -it --network=host dzhw/report-task java -jar /app/report-task.jar --task.id=dat-gra2005-ds2$ --task.version=1.2.3 --task.onBehalfOf=dataprovider --task.language=de --task.type=DATA_SET_REPORT --mdm.username=${MDM_TASK_USER} --mdm.password=${MDM_TASK_PASSWORD} --mdm.endpoint=http://127.0.0.1:8080

For further configuration options you should get familiar with Spring Boot @ConfigurationProperties and have a look into src/main/java/eu/dzhw/fdz/metadatamanagement/tasks/reporttask/config.

Template Editing

The latex files which are compiled within this task are generated with FreeMarker. The templates can be edited under /src/main/resources/template/. Changes to the latex styles and images can be made here: /latex-packages/doc/

Continous Integration

Every commit to the branches development, test or master will be pushed to Amazon ECR. Github Actions are used for executing the build and pushing to AWS.

Issues

If you find any issues or have questions regarding this task, feel free to file an issue in our MDM.