Microservice that exports data from Kaleidos to be published on Themis
3.3K
Microservice that exports data from Kaleidos to be published on Themis.
Add the following snippet to your docker-compose.yml:
export:
image: kanselarij-vlaanderen/themis-export-service
links:
- database:database
volumes:
- ./data/exports/:/share
The final result of the export will be written to the volume mounted in /share.
To run the export querying a Kaleidos triple store on a remote server, setup an SSH tunnel with port forwarding on your docker0 network interface (probably IP 172.17.0.1):
ssh kaleidos-server -L 172.17.0.1:8895:<kaleidos-triple-store-container-ip>:8890
Add an extra host kaleidos to the export service pointing to the docker0 network and configure the KALEIDOS_SPARQL_ENDPOINT environment variable.
export:
...
environment:
KALEIDOS_SPARQL_ENDPOINT: "http://kaleidos:8895/sparql"
extra_hosts:
- "kaleidos:172.17.0.1"
Trigger the publication of the Kaleidos meeting with the given :uuid. In case the meeting has already been published before, the new publication will be linked to the previous one.
Example request body:
{
"data": {
"type": "publication-activity",
"attributes": {
"scope": ["newsitems", "documents"]
}
}
}
The following attributes can be set on the publication-activity:
"newsitems" and "documents". Documents can only be exported if the newsitems are exported as well. To unpublish a meeting, send an empty array as scope.Location response header contains the endpoint to monitor the progress of the job.Get the status of an export job
The following environment variables can be configured:
MU_SPARQL_ENDPOINT (default: http://database:8890/sparql): SPARQL endpoint of the internal triple store to write intermediate results toVIRTUOSO_SPARQL_ENDPOINT (default: http://virtuoso:8890/sparql): SPARQL endpoint of the Virtuoso triple store, in order to extract the ttl files.KALEIDOS_SPARQL_ENDPOINT (default: http://kaleidos:8890/sparql): SPARQL endpoint of the Kaleidos triple storeEXPORT_BATCH_SIZE (default: 1000): number of triples to export in batch in the final dumpContent type
Image
Digest
sha256:94accfd61…
Size
81.8 MB
Last updated
6 months ago
docker pull kanselarij/themis-export-service