diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4b85e03..cb54475 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,8 @@ image: node:lts-alpine +include: + - template: Security/Secret-Detection.gitlab-ci.yml + build_job: stage: build @@ -29,5 +32,15 @@ pages: rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH -include: - - template: Security/Secret-Detection.gitlab-ci.yml +netlify: + stage: deploy + + before_script: + - apk update && apk add curl + + script: + - curl -X POST -d '{}' https://api.netlify.com/build_hooks/$NETLIFY_BUILD_HOOK + + rules: + # Only trigger through schedule job and "Run pipeline" in the main branch + - if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && ($CI_PIPELINE_SOURCE == "schedule" || $CI_PIPELINE_SOURCE == "web")'