Lab 1 Report
link to a successful run of the CI/CD job that executed the game: https://gitlab.stud.atlantis.ugent.be/thomdwil/devops-project/-/pipelines/77180
Report on the structure of the.gitlab-ci.yml file: Stage one and two succeeded quite early. However stage 3 took some time figuring out as I did not realize I had to edit stage 2 in order to let stage 3 succeed. Another problem I encountered were the variables. I misread the instructions and thought I had to initialize them myself in GitLab which was not the case. No other problems occurred aside from these 2.
Questions:
./mvnw is the Maven Wrapper, a script included in a project that automatically downloads and uses a specific version of Maven defined for that project. The advantage of using it over mvn is that it ensures consistent builds across different environments without requiring developers to manually install Maven.
GitLab's cache is used to speed up jobs by reusing files like Maven dependencies between pipeline runs, while artifacts are used to persist and share build outputs between jobs or after the pipeline finishes. Maven dependencies should use cache for efficiency across runs, whereas build files should use artifacts to ensure availability in downstream jobs, trading off cache volatility for artifact reliability.
Using 25-jdk for CI/CD builds provides necessary tools to compile Java code, while using 25-jre for the runtime container reduces image size and attack surface. Using 25-jdk for both increases image size and security risk, while using 25-jre for both would fail at build time due to missing compiler tools.