Every service in the Innovatech Chile platform is packaged as a Docker image using a multi-stage build. The build stage produces the artifact (a compiled JAR or a static asset bundle) and a lean runtime stage carries only the minimum needed to run it. Docker Compose ties all four services together and manages startup order, port bindings, and environment variables.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/DevOpsDuoc/Evaluacion02_Devop_Innovatech/llms.txt
Use this file to discover all available pages before exploring further.
Containerization strategy
- Backend services (Ventas and Despachos) are built with Maven inside a
maven:3.9.9container, then the compiled JAR is copied into aneclipse-temurin:17-jreruntime image. A non-root userappuserruns the process. - Frontend is compiled with
node:20-alpineusingnpm ciandnpm run build, then thedist/folder is served bynginx:stable-alpineat runtime. - Orchestration is handled by a single
docker-compose.ymlin theproyect/root that starts the frontend, both backends, and the MySQL database. - MySQL data is persisted in a named Docker volume (
tienda_db_data) so the database survives container recreation.
Dockerfiles
The
JAVA_TOOL_OPTIONS flag -XX:+UseContainerSupport enables JVM container-aware memory sizing. -XX:MaxRAMPercentage=75.0 caps heap usage at 75% of the memory limit the container sees, preventing OOM kills.Docker Compose
All services are declared inproyect/docker-compose.yml. The image field for each service points to an ECR repository so that the same file works for both local builds and production pulls.
docker-compose.yml
Service dependencies
db first, then the two backend services, and finally the frontend.
Named volume: why not a bind mount
The MySQL data directory is mounted via the named volumetienda_db_data rather than a bind mount. The rationale from the project documentation:
| Concern | Named volume | Bind mount |
|---|---|---|
| Isolation and security | No host paths or file-system dependencies exposed | Exposes host directory paths, prone to permission errors |
| Portability | Managed by Docker, movable between compatible hosts | Tied to a specific host directory path |
| Data integrity | Persists when containers are recreated or updated | Can be affected by host-side file changes |
| Performance | Docker optimises I/O for supported storage engines | Subject to host file-system latency variability |
| Coupling | Keeps the backend stateless and independent | Creates a dependency on local host paths |
Named volumes are the recommended approach for production database persistence. Containers remain ephemeral while the volume outlives any individual container lifecycle.
docker-compose.yml with an explicit name so it is predictable and easy to reference in backup or migration scripts:
docker-compose.yml