Add gitlab pipeline
This commit is contained in:
parent
0def56d219
commit
c214c9aed0
2 changed files with 18 additions and 1 deletions
17
.gitlab-ci.yml
Normal file
17
.gitlab-ci.yml
Normal file
|
@ -0,0 +1,17 @@
|
|||
image: docker:latest
|
||||
|
||||
variables:
|
||||
DOCKER_DRIVER: overlay2
|
||||
IMAGE_TAG: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME
|
||||
|
||||
services:
|
||||
- docker:dind
|
||||
|
||||
build:
|
||||
stage: build
|
||||
retry: 2
|
||||
script:
|
||||
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
|
||||
- docker build -t $IMAGE_TAG .
|
||||
- docker push $IMAGE_TAG
|
||||
|
2
main.py
2
main.py
|
@ -236,4 +236,4 @@ def main():
|
|||
if __name__ == "__main__":
|
||||
print("Speedtest CLI data logger to InfluxDB started...")
|
||||
main()
|
||||
if client then client.close()
|
||||
client.close()
|
||||
|
|
Loading…
Reference in a new issue