diff options
| author | Szymon Szukalski <szymon@skas.io> | 2024-07-25 11:56:13 +1000 |
|---|---|---|
| committer | Szymon Szukalski <szymon@skas.io> | 2024-07-25 11:56:13 +1000 |
| commit | 1df19fd955eb951f5d31fb205963b2f4e794c039 (patch) | |
| tree | 8de7fe9f20c069d4e9907a669e792d4e6c0f75ea /README.md | |
| parent | bac742fe816a349d75db28fc44e5cca22776bb1a (diff) | |
Separate Docker Compose services for build, test, run
Refactor Docker Compose setup to include distinct services for building, testing,
and running the application.
Use separate Dockerfiles and configurations for each phase to isolate concerns and
improve workflow.
Quiet down the maven logs and set log levels to WARN so there is less noise in the
logs.
Update README file with information on running the project.
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 54 |
1 files changed, 53 insertions, 1 deletions
@@ -1,3 +1,55 @@ # Markr - Marking as a Service -**Szymon Szukalski's Submission to the Stile Coding Challenge - July 2024**
\ No newline at end of file +**Szymon Szukalski's Submission to the Stile Coding Challenge - July 2024** + +## Running the Project + +This project uses Docker for building, testing, and running the application. Below are the instructions to incorporate +this project into your build system using Docker. + +### Prerequisites + +- Docker (version 20.10 or later) +- Docker Compose (version 1.29 or later) + +### Build + +To build the Docker image for the application, run the following command: + +```shell +docker compose build +``` + +This command will build the application image using the Dockerfile defined in the project. + +### Test + +To run the tests using Docker, use the following command: + +```shell +docker compose run --rm markr_tests +``` + +This command will build the Docker image (if not already built), start a container for testing, and run the tests. The +--rm flag ensures that the test container is removed after the tests complete. + +### Run + +To run the application, use the following command: + +```shell +docker compose up postgres markr +``` + +This command will start the application and its dependencies (like PostgreSQL) as defined in the docker-compose.yml +file. + +### Cleanup + +To stop the running containers and remove them along with associated volumes, use: + +```shell +docker compose down -v +``` + +This command will stop and remove the containers and any associated volumes.
\ No newline at end of file |
