upload .gitlab-ci.yml
This commit is contained in:
parent
5271ab4a94
commit
6651f11d8e
33
.gitlab-ci.yml
Normal file
33
.gitlab-ci.yml
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
image: docker:dind
|
||||||
|
|
||||||
|
services:
|
||||||
|
- docker:dind
|
||||||
|
|
||||||
|
stages:
|
||||||
|
- build_amd64
|
||||||
|
- build_arm64
|
||||||
|
|
||||||
|
before_script:
|
||||||
|
- docker -v
|
||||||
|
|
||||||
|
build_amd64:
|
||||||
|
stage: build_amd64
|
||||||
|
needs: []
|
||||||
|
script:
|
||||||
|
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
|
||||||
|
- docker buildx build -t snort2:amd64 docker/
|
||||||
|
- docker tag snort2:amd64 $CI_REGISTRY/manalejandro/snort2-api/snort2:amd64
|
||||||
|
- docker tag snort2:amd64 $CI_REGISTRY/manalejandro/snort2-api/snort2:latest
|
||||||
|
- docker push $CI_REGISTRY/manalejandro/snort2-api/snort2:amd64
|
||||||
|
- docker push $CI_REGISTRY/manalejandro/snort2-api/snort2:latest
|
||||||
|
|
||||||
|
build_arm64:
|
||||||
|
stage: build_arm64
|
||||||
|
needs: []
|
||||||
|
before_script:
|
||||||
|
- docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
|
||||||
|
script:
|
||||||
|
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
|
||||||
|
- docker buildx build --platform arm64 -t snort2:arm64 docker/
|
||||||
|
- docker tag snort2:arm64 $CI_REGISTRY/manalejandro/snort2-api/snort2:arm64
|
||||||
|
- docker push $CI_REGISTRY/manalejandro/snort2-api/snort2:arm64
|
Loading…
Reference in New Issue
Block a user