I have used docker-compose to dockerise a python app dependent on a database which works fine. The python app generates a powerpoint file which it stores in /tmp within the container. It then needs to be converted to pdf for the dockerised frontend to render it. I intend to do this using a dockerised libreoffice image https://hub.docker.com/r/domnulnopcea/libreoffice-headless/
The libreoffice container is run as follows
sudo docker run -v /YOUR_HOST_PATH/:/tmp libreoffice-headless libreoffice --headless --convert-to pdf /tmp/MY_PPT_FILE --outdir /tmp
Where YOUR_HOST_PATH is within my python app container
What I need to happen
I need the python app to call the libreoffice container and convert the ppt file residing in the python app container and then make the path of the converted document available for the frontend to render.
Basically how to make files in different docker containers accessible to each other using docker-compose
My docker-compose.yaml:
version: '3'
services:
backend:
image: interrodata_backend
build: ./backend
ports:
- "9090:9090"
depends_on:
- db
environment:
- DATABASE_HOST=db
db:
image: nielsen_db
restart: always
build: ./db