-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
66 lines (50 loc) · 1.53 KB
/
.gitlab-ci.yml
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
include:
- project: 'platform-one/devops/pipeline-templates'
ref: master
file: '/templates/go.yml'
workflow:
rules:
build:
script:
- CGO_ENABLED=0 GOOS=linux go build -v -o bin/apigateway cmd/server/main.go
variables:
TEAM: $CI_PROJECT_NAMESPACE
APP: $CI_PROJECT_NAME
FORTIFY_PROJECT_VERSION: "10"
FORTIFY_INCLUDE: "."
FORTIFY_EXCLUDE: ""
SONAR_COVERAGE_EXCLUSIONS: "**/*_test.go"
TRUFFLEHOG_EXCLUDE_PATHS: "go.sum /docs/swagger-ui/dist"
ZAP_URL: "https://go-world-il2-staging.apps.dso.mil/"
ZAP_SCAN: zap-baseline.py
dependency check:
allow_failure: true
lint:
allow_failure: true
unit tests:
allow_failure: true
fortify:
allow_failure: true
sonarqube:
allow_failure: true
e2e tests:
allow_failure: true
pen test:
allow_failure: true
twistlock scan:
allow_failure: true
# build image:
# image: ${DOCKER_REGISTRY}/pipeline-job/rootless-podman:0.1
# script:
# - echo $HOME
# - export BUILDAH_FORMAT=docker
# - export STORAGE_DRIVER=vfs
# - pwd
# - whoami
# - echo "Building $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA"
# - mkdir $HOME/.docker
# - touch $HOME/.docker/config.json
# - echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /home/rootless-podman/.docker/config.json
# - buildah bud -t $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA -f ./Dockerfile .
# - buildah push $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA
# - echo "Successfully pushed image $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA"