summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
blob: d3591b4c32d1688c76bc6c437fcd282481153f18 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
stages:
  - build
  - test
  - validate
  - runway_staging
  - runway_production
variables:
  CHANGE_LOCK_OVERRIDE: true
  CONTAINER_IMAGE_COMMIT: $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA
include:
  - project: 'gitlab-com/gl-infra/platform/runway/runwayctl'
    file: 'ci-tasks/service-project/runway.yml'
    rules:
      - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
    inputs:
      runway_service_id: authzd
      image: "$CONTAINER_IMAGE_COMMIT"
      runway_version: v3.66.2
build image:
  image: docker:28
  interruptible: true
  stage: build
  services:
    - docker:28-dind
  before_script:
    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
  script:
    - docker build --tag $CONTAINER_IMAGE_COMMIT .
    - docker push $CONTAINER_IMAGE_COMMIT
unit:
  image: golang:alpine
  stage: test
  needs: []
  script:
    - go test ./...