IAP GITLAB

.gitlab-ci.yml 1.58 KB
Newer Older
Lukas Nellen's avatar
Lukas Nellen committed
1
image: corsika/devel:u-18.04
Ralf Ulrich's avatar
Ralf Ulrich committed
2

Ralf Ulrich's avatar
Ralf Ulrich committed
3 4 5
variables:
  GIT_SSL_NO_VERIFY: "1"

Hans Dembinski's avatar
Hans Dembinski committed
6 7
build:
  stage: build
Ralf Ulrich's avatar
Ralf Ulrich committed
8
  tags:
Lukas Nellen's avatar
Lukas Nellen committed
9
    - corsika
10

Hans Dembinski's avatar
Hans Dembinski committed
11 12
  # detect_leaks=0 because leak detection doesn't work in CI, but you can
  # try to test with leak detection locally, just set detect_leaks=1
Hans Dembinski's avatar
Hans Dembinski committed
13 14 15 16
  script:
    - mkdir build
    - cd build
    - cmake ..
Hans Dembinski's avatar
fix  
Hans Dembinski committed
17
    - cmake --build . -- -j4
Hans Dembinski's avatar
fix  
Hans Dembinski committed
18
    - UBSAN_OPTIONS=print_stacktrace=1
Hans Dembinski's avatar
Hans Dembinski committed
19
      LSAN_OPTIONS=log_threads=1
20 21 22 23
      ASAN_OPTIONS=detect_leaks=0:detect_stack_use_after_return=1 ctest -j4 -V -O test.log
  after_script:
    - cd build
    - gzip -v -9 -S .gz test.log
24
  artifacts:
Ralf Ulrich's avatar
Ralf Ulrich committed
25
    expire_in: 1 week
26
    paths:
27
      - build/test.log.gz
Ralf Ulrich's avatar
Ralf Ulrich committed
28
    when: on_failure
29 30
    reports:
      junit:
31
        - build/test_outputs/junit*.xml
Ralf Ulrich's avatar
Ralf Ulrich committed
32

33
pages:
Ralf Ulrich's avatar
Ralf Ulrich committed
34
  stage: build
Ralf Ulrich's avatar
Ralf Ulrich committed
35
  tags:
Lukas Nellen's avatar
Lukas Nellen committed
36
    - corsika
37
  script:
Ralf Ulrich's avatar
Ralf Ulrich committed
38 39 40
    - mkdir build
    - cd build
    - cmake ..
41 42 43
    - make doxygen
    - mkdir .public
    - cp -r Documentation/Doxygen/html .public/
Ralf Ulrich's avatar
Ralf Ulrich committed
44
    - mv .public ../public
45 46 47 48 49 50 51 52 53
  artifacts:
    paths:
      - public
  only:
    - tags
    - triggers
    - schedules


Ralf Ulrich's avatar
Ralf Ulrich committed
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
# code_quality:
#   image: docker:stable
#   variables:
#     DOCKER_DRIVER: overlay2
#   allow_failure: true
#   services:
#     - docker:stable-dind
#   script:
#     - export SP_VERSION=$(echo "$CI_SERVER_VERSION" | sed 's/^\([0-9]*\)\.\([0-9]*\).*/\1-\2-stable/')
#     - docker run
#         --env SOURCE_CODE="$PWD"
#         --volume "$PWD":/code
#         --volume /var/run/docker.sock:/var/run/docker.sock
#         "registry.gitlab.com/gitlab-org/security-products/codequality:$SP_VERSION" /code
#   artifacts:
#     reports:
#       codequality: gl-code-quality-report.json