'How Can I run Karate Api tests via docker and then expose the reports (using docker)?

I have a docker file:

FROM maven:3.6.3-jdk-11 as karate

COPY . /usr/src/app

WORKDIR /usr/src/app/target/cucumber-html-reports
WORKDIR /usr/src/app

Then I run it: docker run --name karate --rm -it imvu_api_mvn mvn test '-Dkarate.options=--tags @feed_comment'

But I can't access the reports because the container exits.

I'd like to know how can I expose the reports after running the tests via docker



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source