diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6285098e4d25c7d4aaced631233641c370bc5312..65f2ddd39c93ad87f5742e5210f42cc55606297d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,6 +12,7 @@ variables: CONTAINER_GCC_GUI_IMAGE: $CI_REGISTRY/ogs/$CI_PROJECT_NAME/$CI_PROJECT_NAMESPACE/gcc-gui:$CI_COMMIT_REF_SLUG XUNIT_TO_JUNIT_IMAGE: $CI_REGISTRY/ogs/$CI_PROJECT_NAME/xunit-to-junit PRECOMMIT_IMAGE: $CI_REGISTRY/ogs/$CI_PROJECT_NAME/pre-commit + WEB_IMAGE: $CI_REGISTRY/ogs/$CI_PROJECT_NAME/web # Build config BUILD_TYPE: Release BUILD_PROCESSES: "" # Empty string: builds all processes @@ -42,3 +43,4 @@ include: - local: '/scripts/ci/jobs/build-gui-mac.yml' - local: '/scripts/ci/jobs/check-header.yml' - local: '/scripts/ci/jobs/tests-large.yml' + - local: '/scripts/ci/jobs/web.yml' diff --git a/scripts/ci/jobs/build_image.yml b/scripts/ci/jobs/build_image.yml index 496cba9582e0ea64df6bacbfb0ea2d950fb7afb6..41b876c4a739229c7362fa1edfdad49aee4e63f8 100644 --- a/scripts/ci/jobs/build_image.yml +++ b/scripts/ci/jobs/build_image.yml @@ -59,3 +59,20 @@ build pre-commit image: - docker pull $PRECOMMIT_IMAGE:latest || true - docker build --cache-from $PRECOMMIT_IMAGE:latest -t $PRECOMMIT_IMAGE:latest -f scripts/docker/Dockerfile.pre-commit scripts/docker - docker push $PRECOMMIT_IMAGE:latest + +build web image: + stage: .pre + rules: + - if: '$CI_COMMIT_BRANCH == "master"' + changes: + - scripts/docker/Dockerfile.web + - scripts/ci/jobs/build_image.yml + tags: + - docker-shell + variables: + GIT_LFS_SKIP_SMUDGE: "1" + script: + - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY + - docker pull $WEB_IMAGE:latest || true + - docker build --cache-from $WEB_IMAGE:latest -t $WEB_IMAGE:latest -f scripts/docker/Dockerfile.web scripts/docker + - docker push $WEB_IMAGE:latest diff --git a/scripts/ci/jobs/web.yml b/scripts/ci/jobs/web.yml new file mode 100644 index 0000000000000000000000000000000000000000..6b6d415806b9f887aeff5f90720c14097212af7d --- /dev/null +++ b/scripts/ci/jobs/web.yml @@ -0,0 +1,19 @@ +web url checker: + stage: checks + tags: + - docker + extends: + - .defaults + - .rules-master-manual + + image: + name: $WEB_IMAGE + entrypoint: [""] + + script: + - cd web + - > + urlchecker check --retry-count 5 --file-types .pandoc,.md + --white-listed-files releases/* + --white-listed-urls https://jenkins.opengeosys.org/job/ufz/job/ogs-container-maker/job/master/build,http://yourproxy.example.com,https://apt.kitware.com/ubuntu/,https://github.com/YOUR-USERNAME/ogs,https://jenkins.opengeosys.org/github-webhook/,http://localhost:1313,https://github.com/ufz/ogs/pull/\$1,http://www.opengeosys.org/images/xsd/OpenGeoSysXXX.xsd,https://\`-protocol + content