-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
42 lines (35 loc) · 726 Bytes
/
Copy path.gitlab-ci.yml
File metadata and controls
42 lines (35 loc) · 726 Bytes
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
# Replace "projectname" and "username"
image: golang:1.15
variables:
BINARY_NAME: yamltojson
ZIP_FILE: yamltojson.zip
stages:
- test
- build
- deploy
test-yamltojson:
stage: test
script:
- go mod download
- go mod verify
- go test -v -cover ./...
build-yamltojson:
stage: build
script:
- go mod download -x
- apt-get update -y
- apt-get install zip -y
- make zip
artifacts:
paths:
- ${ZIP_FILE}
only:
- master
upload-artifact:
stage: deploy
image: python:latest
script:
- pip install awscli
- aws s3 cp ${ZIP_FILE} s3://yaml-to-json-go
only:
- master