Commit 90e6077e authored by Vito Conforti's avatar Vito Conforti
Browse files

Add new file .gitlab-ci.yml

parent aa99ddf0
Loading
Loading
Loading
Loading
Loading

.gitlab-ci.yml

0 → 100644
+26 −0
Original line number Diff line number Diff line
image: openjdk:19  # Use the appropriate Java 19 image

stages:
  - build

variables:
  MAVEN_OPTS: "-Dmaven.repo.local=.m2/repository"  # Custom Maven repository location

before_script:
  - apt-get update -qy
  - apt-get install -y maven

build:
  stage: build
  script:
    - mvn clean install  # Replace with your Maven build command
  artifacts:
    paths:
      - target/*.jar  # Save JAR artifacts

run_jar:
  stage: run
  script:
    - java -jar target/*.jar  # Replace with the actual JAR file name
  dependencies:
    - build  # Run after the build stage